Examples: Set command
Using the Set command to set a percentage for a tag can only be done with HMI tags. Percentage calculations require maximum and minimum values, so you cannot set a percentage value for controller tags because they do not have minimum and maximum properties.
Set Tag1 10
Tag1 is a tag. This commands writes the value "10" to the programmable controller or data server.
Set /area2::Tank\level 50%
Tank\level is a tag with the minimum defined as -100 and the maximum defined as 900. This command writes the value "400" to the programmable controller or data server in area2.
Set Valve\23 open
Valve\23 is a digital tag. This command uses the on label for this digital tag to write a "1" to the programmable controller or data server.
Set Tank\level preset
If the tag preset is 90, the command writes the value "90" to the programmable controller or data server.
Set String\string1 "Open"
This sets the value of the tag string\string1 to Open.
Provide Feedback