The %TriggerValue% token returns the value associated with how the macro was triggered.
Different ways of triggering the macro will set this field differently.
When a Macro is triggered, the The %TriggerValue% token value will be based on the trigger:
|Typed String trigger||the exact text you typed to trigger|
|Status Menu or Palette||the current modifiers (Note that Option means “edit this macro instead of triggering it”).|
|Hot Key Trigger or USB Device Key||The key that was pressed.|
|Application Trigger||application name|
|Folder Trigger||path of the file that was added or removed|
|Execute a Macro action|| Although Execute a Macro is not technically a trigger, when a Macro is executed by this method (the “Sub-Macro”), the %TriggerValue% token (as evaluated in the “Sub-Macro”) will be either of two values:
1. The %TriggerValue% of the calling (“Main”) Macro
2. The value of the Parameter of the Execute a Macro, if a Parameter is provided.
To use the %TriggerValue% token in a numeric field, use the CALCULATE function: CALCULATE(%TriggerValue%).
You can easily access the individual parts using the token array notation, eg
%TriggerValue% will be the third comma-separated value, and
%TriggerValue;% will be the third semicolon-separated value, and
%TriggerValue % (note the space between the
] and the
%) will be the third space-separated value (8.0.4+).