Skip to main content

FieldLogs

Template Variables

A Template can have variables associated with it. Template Variables hold values that can be used within the Template.

Template Variables can be used by Scripts. The values can also be assigned at runtime before the Task is run.

To create a Template Variable:

  1. Open an editable Template to which a variable needs to be added. Navigate to the Variables Tab in the Property Pane.

    CreateVariable1.png
  2. Click New Variable.

    CreateVariable2.png

    Enter the values for the fields displayed as seen below:

    CreateVariable3.png

    Field

    Description

    Variable Name

    Name of the variable.

    It can only contain alphanumeric characters and underscores (_).

    Variable Description

    A description of the variable and its purpose.

    Variable Data type

    The following Data Types are available.

    Data type

    Description

    Value

    Any text value

    Date

    Date values

    Number

    Any numerical value

    Integer

    Integer value

    GPS

    GPS value

    URL

    URL value

    Object

    Object value

    Text customization

    Step text replacement

    Required Toggle

    This sets the variable as required/not required.

    By default, the variable is set as mandatory and the toggle is displayed in red Mandatory_button.png.

    Clicking the toggle sets the variable as not mandatory and the toggle is displayed in gray Mandatory_button_unabled.png.

    Variable Value

    The value assigned to the variable.

  3. Click Save to save the Template. The variable is now ready to be used in the Template.

    CreateVariable4.png

Below are some sample Template Variables.

Variable Description

Variable

A variable of type Value

This variable stores a text value.

CreateVariableValue.png

A variable of type Date

This variable stores a Date value.

CreateVariableDate.png

A variable of type Number

This variable stores any number, including decimals.

CreateVariableNumber.png

A variable of type Integer

This variable stores only Integers.

CreateVariableInteger.png

A variable of type GPS

This variable stores address information.

CreateVariableGPS.png

A variable of type URL

This variable stores a URL.

CreateVariableURL.png

A variable of type Object

This variable holds an Object type.

CreateVariableObject.png

To know more about Object variables, click here.

A variable of type Text Customization

This variable replaces selected text in Steps with the specified text replacement.

CreateVariableTC.png

To know more about Text Customization variables, click here.