Automatically change upload file dialog viewing preferences by folder selected?

I take and upload screen shots quite regularly.

Safari’s interface for uploading a file retains the viewing options you selected the last time you used the dialog. For screen shots I almost invariably want to select the last screen shot I have taken, and to find this I need to view my Screen Shots folder in the List view, sorted by reverse Date Modified. However for almost any (every?) other folder I would prefer the window showed the contents in Column view, sorted in alphabetical order. Constantly flipping between the two drives me nuts!

(Finder itself remembers viewing preferences on a folder-by-folder basis, but the downloads dialog doesn’t.)

Would it be possible to use KM to have the upload dialog effectively default to Column view, sorted in alphabetical order except when I selected a specified folder, which it would always display in List view, sort by reverse Date Modified?

(Failing that any ideas about how else this might be achieved? I haven’t been able to find anything on the web for this)

There is likely a way, but if you know its the last one you took you can just find that yourself within the macro.

Firstly, if the image was on the clipboard instead, then you can use this macro.

If it is already in the Screen Shots folder, then it is just a question of looking for the latest file. Basically just scan the folder looking for a pdf (or whatever) file with the latest modification date.

Find Latest File.kmmacros (5.5 KB)

This will likely suffice for my purposes. (Although I'll have to create a variant which incorporates the retina-downsizing action you gave me a few days ago.)

I'll have to play with the second. It's not working properly even after I convert the filetype to .png, but obviously I now have a great foundation for the macro, so I'll just have to step through it methodically and work out why it's giving me an empty dialog box at the end.

Cheers

1 Like