Application launch trigger

I’ve seen this issue before, and possibly an answer, but I can’t find it anywhere, including this forum and the manual/help for KM. I’d appreciate any guidance.

Trying to get a macro to run when one of a few certain applications launches. The task of the Macro is to select a specified menu item in the launched application (after it’s finished launching of course). I have a Macro Group that is set to be Available in the applications I want this Macro to trigger in.

I’ve tried various approaches here and each one is giving me different errors or issues. Rather than describe in detail (yet, I can if needed) what I’m doing and what error messages I’m getting, it seems the simple thing to do is just ask: What’s the way I’m supposed to do this? How is KM designed when it comes to this goal?


I'm afraid you may have to provide that detail, because from what you've told us so far the only thing I can suggest is that this macro probably needs to be in a global macro group, rather than one limited to just the applications you want the macro to be triggered in. See for a bit more information.

That said, I can show you an example of a working "select menu when application is launched" macro. Essentially, it just needs to pause long enough for the app to finish launching (and as per the above, it's in my global macro group, not one that's limited to certain applications):

You want to use a Application Launched trigger, but Keyboard Maestro will actively complain if you put this in a macro group that is specific to the application because then it will never fire - it only becomes active after the application launches, so the launch trigger will never first and the macro will never execute.

You need to put the macro with the Application Launched trigger in a globally active macro group.

Also, I encourage you to use the Help ➤ Assistance window and click the Something expected is not happening link if the macro does nothing since it might help narrow down the problem.

Hi Peter, and gglick. Just a quick note to say thanks for the explanation. Thought I posted this thanks months ago but seems I didn’t. Putting it in the global group solved that problem. Although there’s another problem. But that’s for another thread. Thanks again!