Set Variable
Associated with: ST Programs, Function Block Diagrams, Ladder Diagrams, Sequential Function Charts. This action is also available on ST Libraries but has no effect
Security permission required to access this pick action: Control
Use the Set Variable action to define the value for a variable in a Logic program. This is useful when you need to test that a Logic program uses a variable as expected, prior to setting the Logic program as ‘live’ on your system. For example, let’s say you create a Logic program that is to trigger an action when a Boolean input variable is True. During testing, you can use the Set Variable action to set the variable to True so that you can check that the Logic program responds to the True value with the expected response.
When you select the Set Variable action for a Logic program, a Set Variable dialog box is displayed. In the dialog box, enter the Name of the variable you want to set, then use the Value field to define the test value. The defined value will be applied to the specified variable and will remain in place until it is overwritten by a reported value or you set the variable manually.