Play Quick Macro with MIDI

Here's one that's stickier than I'd anticipated: I love my Quick Macros, and have at least five enabled by default. I've got a big MIDI footswitch board that I'm playing with, and am interested in buttons 6-10 recording Quick Macros 1-5, with buttons 1-5 playing those Quick Macros.

The recording function is naturally simple, just assigning the trigger to a MIDI event. It's the playing of the Quick Macro that's problematic - "Play Quick Macro hot key" will only accept input as a keyboard shortcut or script - no option for MIDI input there. Making a separate Macro to trigger the Quick Macro hot key (opt F1) by MIDI doesn't work, the result of that Macro (opt F1) isn't triggering the Quick Macro. Trigger Macro doesn't appear to be an option as well.

Do I need to go a scripting route, or is there a feature I'm overlooking? I don't want to involve any third-party softwares as a workaround, this is something KM should be able to do on its own.

I had never looked into the Record Quick Macro, but have just tried it out…

  1. I made a test macro with "Play quick macro hot key" set to ⇧⌃⌥⌘-N.
  2. I created another macro.
    a) I added the Type a keystroke action, and set it to ⇧⌃⌥⌘-N.
    b) I set a MIDI trigger for the macro.

It worked. The MIDI trigger caused the "quick macro" to play.

Suggestions:

  1. Try a different quick macro hot key. ⌥-1 is quite commonly used by applications, so perhaps a conflict is resulting in your setup.
  2. Make sure that both macros are active.

Ended up getting this done with Applescript, which turned out to be quite simple.

In the Record Quick Macro action, select dropdown menu "Or by script." and copy the resulting Applescript. In the macro being triggered by MIDI input to play back the macro, add action "Execute Applescript" and paste the copied Applescript.

Thanks for letting us know that you have found a satisfactory solution (and yes, I meant to type option-fn1!) .