Diese Dokumentation bezieht sich auf Macro Recorder v3 beta. Klicken Sie hier für die Dokumentation der Produktionsversion 2.

Variablen

Some macro actions create data which you most probably want to use in a other macro actions in your script.

Examples:
  • The ImageFind action finds the X/Y coordinates of an image.
  • The on-screen text recognition gets the text found on screen.
  • The result of the math calculation is stored in a variable.
  • The clipboard can also be stored in a variable.

To transfer such data between actions, so called "variables" are used as data storage places. A variable consists of a name of your choice such as "FoundX".

For example, Macro Recorder can find the X/Y position of a picture on the screen and store the X and Y coordinate in variables "ImgX" and "ImgY". These variables are later used by a mouse click action that clicks on the X/Y coordinate stored in those variables.

Variables can also be used to transfer and exchange data with the productivity solution PhraseExpress.

Variables are volatile and dismissed on program shut-down.

Variable erzeugen

To define a variable, simple type in the desired name in the corresponding input box in the dialog window of any Macro Recorder action that generates data:

You can also use the "Set variable" action to create a new variable and/or set the contents of an existing variable:

Variablen verwenden

To use a variable, enter its name or select from any existing variable that has been defined earlier in your script:

You can also use variables, created in Macro Recorder in the productivity solution PhraseExpress. Macro Recorder can also read variables defined in PhraseExpress.

Berechnung

Macro Recorder kann Berechnungen mit Variablen durchführen und das Ergebnis in einer Variablen speichern:

Mit dieser Funktion können Sie zum Beispiel Zähler erstellen, den Abstand zwischen mehreren auf dem Bildschirm gefundenen Bildern oder Texten berechnen oder Mauskoordinaten-Offsets berechnen.

Supported operations, functions and constants

Operations:

+, -, *, /,
^, ** - power
! - factorial
(, ) - brackets

Functions:

sin, cos, tan, ctg, abs, sqrt, ln

Constants:

pi, e

Inhaltsverzeichnis


Inhaltsverzeichnis