Difference between revisions of "Trigger: Macro enabled"
| Line 48: | Line 48: | ||
''' See Also ''' | ''' See Also ''' | ||
| − | * [[Trigger: | + | * [[Trigger:_Macro_finished|Macro Finished Trigger]] |
* [[Trigger:_MacroDroid_Initialised|MacroDroid Initialised Trigger]] | * [[Trigger:_MacroDroid_Initialised|MacroDroid Initialised Trigger]] | ||
* [[Action:_Enable/Disable_Macro|Enable/Disable Macro Action]] | * [[Action:_Enable/Disable_Macro|Enable/Disable Macro Action]] | ||
Latest revision as of 13:44, 6 January 2026
The Macro Enabled trigger fires whenever the macro containing this trigger is enabled. This can happen when the macro is manually switched on, when its category is turned on, or when the macro is enabled via another macro.
Options
This trigger has no configurable options. It automatically fires when the containing macro is enabled.
Examples
Example 1: Initialize Variables on Enable
Triggers Macro Enabled
Actions Set Variable - counter = 0 Set Variable - last_run = [date_time] Popup Message - Macro initialized
Initializes variables and shows a confirmation when the macro is enabled.
Example 2: Start Background Service on Enable
Triggers Macro Enabled
Actions Enable Macro - Background Monitor Set Variable - service_running = true
Enables a related macro and sets a status variable when the main macro is enabled.
Notes
- The trigger fires when the macro transitions from disabled to enabled state.
- It fires for any method of enabling the macro:
- Manual toggle by the user
- Category being enabled
- Enable Macro action from another macro
Use Cases
- Initializing variables when a macro starts
- Displaying setup/welcome messages
- Starting related services or macros
- Logging macro activation times
- Performing one-time setup tasks
See Also