Read and Review Automation Anywhere Documentation

Automation 360

Close Contents


Open Contents

Create a variable

  • Updated: 10/18/2021
    • Automation 360 v.x
    • Build
    • RPA Workspace

Create a variable

Create a variable to store values.


To create and configure a variable, follow these steps:

  1. From the Bot editor, click Variables > Create variable (+ icon) at the top of the Variables menu.

    variable menu screenshot

  2. In the Create variable window, enter a descriptive name for the variable that is prefixed by a lowercase letter to indicate the variable type.
    For example, sCellValue to indicate a string data type.
    • You can use double-byte characters, such as Chinese, Japanese, or Korean characters, in a variable name. Unicode range supported in variables
    • Variables cannot be named Java keywords such as String, Boolean, Integer, Public, and Finally.
  3. Optional: Enter a description.
    Recommendation: Provide meaningful variable description when defining input or output variables.
  4. Optional: Select the Constant (read-only) option to ensure values cannot be edited or overwritten.
  5. Select from the following options:
    This field pertains to using a bot to run other bots. See Task Bot package.
    • Use as input: The variable holds a value that can be passed from the parent bot to a child bot. (Applicable only to a child bot).
    • Use as output: The variable holds a value that can be passed from a child bot to the parent bot. (Applicable only to a child bot).
    • Both: The value can be passed in both directions.
    • Neither: The variable is confined to this bot; it cannot be shared across other bots.
  6. Select a data type from the drop-down list.
    For more information on data types, see Variable types.
  7. Optional: Enter a default value to assign to the variable.
    The values are NULL/empty by default.
  8. Click Create.
    The variable appears in the Variables pane on the left side of the Bot editor.
  9. To insert a variable into an action field, perform one of the following actions:
    • Click F2 to open the variables list.
    • Click the Insert a value icon, located on the right side of the field.
    • Enter the variable name. As you type, the field generates suggestions of existing variables.
      Note: Add a dollar sign at the start and end of the variable. For example, $myVariableName$.

Next steps

Build a Go be Great bot: Follow the steps in this procedure for an example of how to create a variable and assign it to an action.
Send Feedback