In this chapter you will learn how to create, read and write variables.
Add variables to the data sources
You can add variables to all data sources that have already been created.
Open the
‘Variables’ node in the Project Explorer. There you will find the following variable types, or:
– External variables
– Pointer variables
– Internal variables (global)
– Internal variables (local)
– System variables
Click on the desired variable type to open the corresponding list and save it.
To create a new variable (e.g. external, internal or pointer), click on the ‘+’ button.

Reading variables
Variables can be read using rules on the one hand and using the JavaScript variable change and API function“getVariable” on the other.
For the desired option, please refer to the respective article:
Reading variables using JavaScript – Variable change events
Reading variables using JavaScript – API functions
Writing variables
Variables can be written using actions(SET_VARIABLE) on the one hand and using the JavaScript API function“setVariable” and“setVariableSync” on the other.
Please refer to the relevant chapter for the desired option:
Writing variables using actions
Writing variables using JavaScript – API functions
