DocsVariablesClear Variable

Clear variables (one/all) in RunMacro

RunMacro RunnerRunMacro 3.5+

The Clear Variable command resets variable data in three modes: clear a single variable, clear all Dynamic variables, or clear everything (Global + Dynamic).

Dialog & quick setup

RunMacro Clear Variable command configuration dialog showing parameter fields
Configuration dialog and parameter fields for the Clear Variable command in RunMacro.
  1. Add a Variables › Clear Variable command.
  2. Choose the mode: Single / All Dynamic / All.
  3. For Single, enter the variable name. Save.

Options reference

Mode (Single / All Dynamic / All)

Clearing scope: one variable, all Dynamic, or everything.

Variable name (for Single)

The variable to clear in Single mode.

Modes & when to use

RunMacro Runner

Best for

  • Reset temporary variables before a new processing loop.
  • Remove sensitive data (a password) after use.
  • Reset all variable state when needed.

Use an alternative when

  • Do not use Clear All while the workflow needs Global/Dynamic state; clear only the required scope.
Before you run
  • Add Clear Variable to the macro.
  • Prepare the data or target that Clear Variable will use.

Example workflow

Example: reset Dynamic variables each loop

  1. At the start of each loop, add Clear Variable mode All Dynamic.
  2. Then assign fresh data for that loop.
Expected result: After execution, Clear Variable completes the described action and makes its result available to the next step.

Tips & limitations

The All mode also clears Global variables — think twice if the workflow still needs them.
  • State clearing has no automatic recovery; later steps can receive empty values or lose intermediate data.

Applies to RunMacro 3.5+ · RunMacro Runner · Windows 10/11

RunMacro robot

Robots do the work. Your time is yours.

Create a robot in minutes, no coding needed. Reliable execution, remote management, transparent costs — and you always stay in control.