I’m not quite sure where this action/script came from (the AppleScript looks more complex than one I would write), but I use it all the time and its very handy. It gets the path of the front window in Preview. It should work in pre 10.9, but 10.9 or later is much easier since Preview regained its AppleScript dictionary, so the simple AppleScript:
path of document 1 of window 1 of application "Preview"
is all you really need, but packaged as a plug in is still a bit nicer.
Get Preview Window Path.zip (17.1 KB)