Topology > I/O Devices > Import Variable Tags from an External Data Source > Referencing Variables
Referencing variables

Variables can be used to temporarily store information. Variables can be defined either globally in the <param> section of the XML file or locally in an <input> or <output> section.

Variables are defined using the <string> tag as shown in XML template tags. For example:

    <string name="MyIODevice">DISK_PLC</string>

To refer to a variable, use the following syntax:

    {SectionName.VariableName}

and for this example:

    {parameters.MyIODevice}

The SectionName can be omitted if you are referencing a variable defined in the same section.

Variables are evaluated sequentially in the XML file. Variables in the <param> section are assigned first, followed by those in the <input> section, followed by variables in each <output> section in sequence. This means that:

Published June 2018