Prompt w/ Enabled Macro Groups→Containing Macros→Edit/Run Macro (v11.0.2)

Revised version of requested macro shared in How to list current active macro groups

  1. Choose from a list of enabled macro groups
  2. Choose from resulting list of macros within the selected group
  3. Defaults to editing the chosen macro. Command (⌘) modifier runs the macro.

The basic AppleScript is useful for working with groups/macros and their properties.

-- Get list of enabled macro groups
tell application "Keyboard Maestro"
	return name of macro groups whose enabled is true
end tell
-- Get the variable where we stored selected group from the first prompt
set kmInst to system attribute "KMINSTANCE"
tell application "Keyboard Maestro Engine"
	set asSelectedGroup to getvariable "Local__SelectedGroup" instance kmInst
end tell

-- Get list of all macros in selected group
tell application "Keyboard Maestro"
	return name of every macro of macro group asSelectedGroup
end tell

Prompt w- Enabled Macro Groups→Containing Macros→Edit-Run.kmmacros (11 KB)

Macro Image

4 Likes

Hello @evanfuchs . Excellent macro. Thank you very much. I often need to navigate from one macro group to the other. Would it be possible to add a modifier, for example ⌥ Option which would allow the user to navigate to the macro group selected in the list ?
Once again, congratulations for a very useful macro.

Sure thing @ronald. Glad you like it!

This version should do what you need.

Prompt w- Enabled Macro Groups→Containing Macros→Edit-Run.kmmacros v1.1 (14 KB)

Use the ⌘ modifier in the first prompt to jump to that group in the editor. Or select the group (without modifier) to fire the second prompt with the list of macros in the selected group. Select one to edit it or ⌘ modifier to run it.

Macro Image

3 Likes

Fantastic ! Works perfectly Thank you very much @evanfuchs !

1 Like