Message 1 of 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I am trying to set the suppression state of a constraint based on a shared variable value, and it just does not seem to work. I have renamed the constraint to "Cap", and the shared variable is called "CHSS".
The three values of this variable are: "NG250_WS_RH", "NG250_WS_LH", and "NG250_WS_NIL".
This is the code I am using:
'Set Cap constraint If SharedVariable("CHSS") = ("NG250_WS_RH") Then Constraint.IsActive("Cap")= True ElseIf SharedVariable("CHSS") = ("NG250_WS_LH") Then Constraint.IsActive("Cap") = True ElseIf SharedVariable("CHSS") = ("NG250_WS_NIL") Then Constraint.IsActive("Cap") = False End If
I have also tried this:
'Set Cap constraint If SharedVariable("CHSS") = "NG250_WS_RH" Then Constraint.IsActive("Cap")= True ElseIf SharedVariable("CHSS") = "NG250_WS_LH" Then Constraint.IsActive("Cap") = True ElseIf SharedVariable("CHSS") = "NG250_WS_NIL" Then Constraint.IsActive("Cap") = False End If
What do I have wrong?
Solved! Go to Solution.