Returns the toggled value from the contents of numValue tag.

Function Group Execution Windows Embedded Thin Client
Toggle Logical Synchronous Supported Supported Supported


Toggle( numValue )
Boolean tag containing the value to be toggled.

Returned value

Numerical result (0 or 1) of the value to be toggled.


This function does not actually change the value of the tag, but it can be used in a command or operation that does.


Tag Name Expression
Tag Toggle( MyBoolTag ) // Returned value = 1 if MyBoolTag value equals 0, or 0 if MyBoolTag value equals 1
Tag Toggle( numValue ) // Returned value = toggled value of the number in the numValue tag