Trouble Closing Tabbed Windows in the Finder

This action works on a window in Finder unless Finder is set to use tabs for new windows.

Then, the action will only close a tab if it's the frontmost.

Is there another command somewhere in KM that will allow me to close a tab in Finder?

How about using AppleScript?

Close Finder Tab by Name.kmmacros (20 KB)

Macro screenshot

Hey Matt,

Neil's idea to use AppleScript is the way to go.

You could play some funky games using the Finder's Window menu, but you still have the problem of acquiring the name of the available tabs.

Apple hasn't provided good automation tools for working with tabs.


Thanks for the suggestions.

The more I look at it, the more I think I've tripped over a bug or unwanted behaviour in KM.

KM can close a named tabbed window in Finder. It just has to be the tabbed window that was at the front the last time Finder was in use.

Not KM, but the toolset Apple make available to KM for Finder interaction. While not as bad as Spaces, Finder tabs are another of Apple's "good ideas" that have had little love on the automation/accessibility side.

That sounds likely. So I don't suppose there will be a resolution on Apple's end, and I'll explore the suggestions made for KM.

And thank you to whoever has changed this thread's title to something more meaningful. This is a great forum.

1 Like