Using 'Select Menu Item' Macro When Item's Name Changes

Hi,

I'm using the SELECT OR SHOW A MENU ITEM macro, which works great. But, my menu item changes in my application (AVID) depending on the state of the window. It will go from something like 'SFX' to 'SFX (sorted)'. Is there a simple way to work around this?

Thanks,
Aren

Hello Alph,

I don't have AVID to test but check out this solution from @gglick and see if you can modify it for your liking.

Yes. If the menu item will always start with the same characters, just use this as the menu item name:
^SFX

The "^" tells KM to match any menu item that STARTS with the following characters.

See Select or Show a Menu Item action.

3 Likes

Beautiful. Thanks!

Thanks kcwhat! This isn't exactly what I was looking for but it's awesome anyway. Thanks!

I have a similar issue but I need to run a service and the service is always in the application name menu. So sometimes it will be in Scrivener and other times in MS Word, Text Edit etc. Is there a way around this?

Hey @skillet,

Easy enough.

Menu ⇢ Services Menu.kmmacros (1.9 KB)

-Chris

1 Like

Awesome, thanks Chris! How do you know so much?

1 Like

15 years of using Keyboard Maestro nearly every day?  :sunglasses:

-Chris

3 Likes

Thank you so much for sharing that knowledge with others. You have helped me directly and indirectly so many, many times! I've been away for awhile with a new gig but getting back into the swing of things again.

1 Like

He probably also knows he can select Help from the action (gear) :gear: menu which would tell him all about the things that the Select Menu Item action can do.

1 Like

@skillet The Select Menu Item docs say

The Select Menu action allow you to specify multiple options separated by a vertical bar (eg Show|Hide) to allow for toggling or varying menus.

That might be the ticket if you know in advance how the menus change. I've not used this capability, but SFX|SFX (sorted) might get you what you want.

Hey Paul,

@JMichaelTX's solution in post #3 solves @alph's problem nicely and doesn't require exact foreknowledge of all the possible menu names.

Nevertheless the method you propose has its uses.

-Chris