Binding Associations
Binding Associations are used when there is no direct way of converting a tag value to a property, i.e. converting a Boolean value to a color. Associations allow you to create a mapping table that specifies the value to use for a given tag. Associations can also be used to convert from an integer to a color, a Boolean to a string, and/or a string to a color.
For example, a Rectangle can be added to a WebPage, and its Line Color parameter could be set as an association to a Boolean result, where False would indicate Red and True would indicate Green.
- To create an association, add a Rectangle to the Web Page.
- In the Rectangle Properties, click the beside the Line Color parameter to launch the Expression Builder.
-
Press the Tag button.
-
Select a tag that returns a Boolean result.
-
Press the Associations button to create the conversion association.
-
This will launch the Binding Associations dialog.
-
Uncheck the checkbox, and from the color drop-down menu, select Red for False, then press the Add button.
-
Check the checkbox, and from the color drop-down menu, select Green for True, then press the Add button.
-
Press the Accept button to complete the association.
-
Put the job online, and the Rectangle's Line Color should be Green when the result returns True, and Red when it returns False.