Graphics Builder > Dynamic Associations > Use Constants with Dynamic Associations

Use Constants with Dynamic Associations

You can use the following types of constants with dynamic associations:

To pass a constant you need to format the argument in the association function to include a single quote on either side. For example, to pass the constant data 1.2345 into a dynamic association, you would call the association function like this:

Ass(hWin, sArg, "'1.2345'");

To pass a variable tag or 'equipment.item' tag reference, you don't need the single quotes. For example, to pass variable tag TAG1 into a dynamic association, you would call the association function as follows;

Ass(hWin, sArg, "TAG1");

Or if using 'equipment.item' to reference the variable tag:

Ass(hWin, sArg, "Pump.Speed");
				

The ability to pass constants into dynamic associations is restricted in that the constant association can be used where you can enter a normal Cicode tag. For example, a keyboard command, a symbol address field, and so on.

See Also

Published June 2018