Using variables and functions in MouseRobot


Variables and functions are the special keywords in MouseRobot, designed to store and process data during task execution.

In the simplest case, the variable of MouseRobot is a word or phrase in braces, e. g {Windows Directory}. During task execution, the variable is replaced by its value, which is matched with the variable before or immediately at the time when it is addressed to.

Variables are divided into the Built-in ones (e.g. ({LastResult}), to which the program assigns values automatically, and the user ones, where the values are explicitly assigned in steps (for example, using the "Set variable or call function" step).

Unlike the variables, the functions take one or more parameters, on the values of which they calculate the result.

Examples:

{UserDocumentsDirectory} is a built-in variable instead of which a full path to "My Documents" will automatically be placed during execution
{Sum (2,2)} is a function that adds two numbers and returns the result (in this case - "4")
The use of variables in the text in the step "Mouse and Keyboard”:

The list of built-in variables and functions is given in the directory, and for quick insertion, you can use the drop down menu button "Value" ("V").