AppleScript to open new Finder window in same folder as frontmost window

May 10, '13 07:30:00AM

Contributed by: kirkmc

A user at Stack Exchange asked an interesting question recently : how can you open a new Finder window in the same folder as the frontmost window? When you open a new Finder window (Command-N in the Finder), it opens to the folder you've set in the Finder's General preferences. There may be some situations when you want to duplicate the current window, such as when you're moving files around among sub-folders in a specific folder.

Another reader, Lauri Ranta, posted a simple AppleScript, that you can use together with a keyboard shortcut, to do just this. When you run the script, it creates a new window at the same location as the frontmost window. Here's the script:

tell application "Finder"
    try
        target of window 1
        make new Finder window to result
    on error
        make new Finder window to home
    end try
end tell
Save this as a script, and use any tool that can apply keyboard shortcuts to AppleScripts. Or save it as an application, drag it to the Finder window toolbar, and it'll be just a click away. (You can move the application to any location you want afterwards.)

Comments (6)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20130510015954305