Request: Ability to Sort Different KM Folders Differently

Hi there!
I love Keyboard Maestro and use it constantly.

I have a KM smart folder that shows macros used in the last 12 hours. It is most useful to view this folder sorted by Date Used, so that they appear in order of use.

Other folders are more categorical– Usually centering around an app. I find it most useful to view these sorted alphabetically, so I can find whichever macro I'm looking for, and it will always be in the same place.

Another example would be– The Sort Macros By Use Count option would be more useful if it could be assigned to an individual smart folder.

That being said, as lazy as it makes me sound, switching a global Sort Macros As menu item when switching from viewing one folder to another is just cumbersome enough that I generally don't bother.

Just a thought!
Loving the new updates.

Update: 7 minutes later I've made a macro that changes the Sort option based on the title of Keyboard Maestro's front window. Sometimes typing out what the problem is is the best therapy lol.

4 Likes

I'm glad you took the time to post this and then also the solution you came up with.

I too have thought it would be nice to sort macros differently depending on which macro group I'm in, but hadn't thought of what you came up with. I'm gonna repeat that on my computer now haha. Thanks for sharing!

For anybody who is interested in this, below is the way I copied @82Taylor's idea. No doubt he has something similar and probably better.

EDIT: I added and IF action to make the macro run better. I also posted it to the macro category here. All subsequent updates will be posted in that thread as well.

23)Macros- sort according to focused group.kmmacros (14 KB)

1 Like

Yeah– It seems we've both found the defining feature of a Smart Group can sometimes be the way it's sorted.

You're using this for more things than I am too!

It's so interesting to see someone else's macro that does the exact same thing but in their own unique way. I didn't know there was a WindowName token!

I find myself about to say I would have used a Front Window condition rather than text, and an Otherwise condition rather than a Does Not Contain, BUT I wonder if your choices here have benefits I just don't realize.

This morning for example I found out that using a ScreenCount() calculation to detect an external monitor doesn't work if the monitors are mirroring eachother (I guess they're considered the same screen then), and that it was better to use a %Screen%External% token with an Is Not condition set to 0,0,0,0.

1 Like

Update: Added a third category for mine, and had to switch from an If Then to a Switch like you've used, and I get why you used a text condition with a token now– Front Window title conditions are not available for switches! Your solution already came in handy

1 Like

Yep! That's why I typically use switch actions instead of if/then since I will have multiple subsequent actions.

If I have multiple conditions that determine the following actions, that's when I'll use an if/then action since you can set multiple conditions.

Glad you were able to figure out the screen tokens to refine yours, and thanks again for posting your good idea!

-Chris

1 Like