The Graphical Script Editor Blocks Optional Blocks-Variables Set Variable
Set Variable
You can define a new variable here by assigning it a name and a value. A variable, which has already been defined, can be assigned a new value here.
Furthermore, you can also call those Visual Basic Script functions and sub-programs, which you have defined in the “Start rule” block. Initiate this by going to the window “Set Variable” and leaving the variable name empty. Then enter the expression “=<Name of sub-program()>” in the “Variable value” field. If you would like to use the return value of this function in script, add the appropriate variable name.
You can also create a list of sub-programs here in the same way you would create a variable list. All sub-programs listed here will be executed sequentially.
See also The Use of a Visual Basic Script.
The action will be terminated
* if the variable has been saved, or
* the call has been terminated.
Under "Properties", all three tabs "General", "Parameters" and "Connections" tabs are available for this block.
This is how you set a variable
1 You will see the list of existing variables on the “Parameters” tab.
2 Click on.
The following window appears: Set Variable Value”.
3 Enter a name for this variable by
* entering a new name (A-Z, a-z, 0-9 and _ are allowed, however the first character must be a letter) or
* select a name from the drop-down list.
4 Enter the contents of the variable in the field “Variable value”. This assigns a start value to a new variable or it defines the value of an existing variable with a new value. This value can then be evaluated in sequence, e.g. using the block “Evaluate”.
The variable value can be a string. If the entry in this field begins with an equal sign, all characters which follow will have a numeric value or be interpreted as an expression. In doing so, you can enter existing variables and system functions. Click on and select the variable from the list which appears.
See also Variables and System Functions.
5 Click on "OK" to close the window.
Once this block is reached, the variables will be set according to your entries. The “Set Variable” block can be seen on the grid interface and it available for further processing.