Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TugboatEng on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Repeat-region relation does not work - ”Constraint has been violated”

  • Thread starter Thread starter Johan W
  • Start date Start date
J

Johan W

Guest
I have created a feature parameter for my assembly, which I call SPC_NO. (when I add it to the assembly, this parameter is defined as a value).

When i generate my repeat-region I want the following senario:

If the CAD-objects in the assembly have a parameter called SPC, the feature parameter SPC_NO will reflect SPC. If the CAD-objects lack the parameter SPC, SPC_NO should be equal to (string) "SP".

I tried to solve this for my repeat-region with the following relations:

IF ("&asm.mbr.SPC"!="")
"&asm.mbr.cparam.SPC_NO"=="SP"
ELSE
"&asm.mbr.cparam.SPC_NO"=="&asm.mbr.SPC"
ENDIF

I get the message: ”Constraint has been violated”. Has this something to do with the definition of the feature parameter SPC_NO? I tried to manually change the feature parameter from value to string for all the CAD-objects, but i still get the same error message.

We use Creo 2.0 and we should be able to update a feature parameter depending on the value of other parameters. Please help me solve this puzzle...
 
If I remember correctly, it is not possible for the repeat region of an assembly drawing to change a parameter in a part.

It is possible to have the repeat region show the parameter SPC_NO or SP if it doesn't exist, but I don't remember how at the moment - I think that it was previously asked on this site.
 
This is not a parameter in the CAD objects. I trying to create a feature parameter for my assembly (I want the same cad object to have different values depening on the assembly)

If one forget the repeat region, is it possible to update the feature parameter if you add the same code in Tools --> relations in your CAD assembly?

IF ("&asm.mbr.SPC"!="")
"&asm.mbr.cparam.SPC_NO"=="SP"
ELSE
"&asm.mbr.cparam.SPC_NO"=="&asm.mbr.SPC"
ENDIF
 

Part and Inventory Search

Sponsor

Back
Top