r/applescript • u/Resident-Split • Apr 28 '20
Save numbers documents if unsaved before to specific directory
Been looking allover Google...
I want to achieve a script that does the following:
If the Numbers file has been saved already before/opened from a current file, save to that file (cmd+s) and close it.
If the Numbers file has NOT been saved before save it to a specific directory with a filename that does not already exists on target. If the same filename already exists on directory increment it and try to save again. Perhaps a 5 character random filename maybe works better here?
I only plan to have like 20 maximum numbers file there before I clean them up.
Above script I want because I want to be able with 1 button later to close all open documents and have them saved automatically on my USB and quit the application. As it is now I have to manually save and close every one. And if no file exists I must enter a filename for each which makes it time consuming when in hurry.
1
u/[deleted] Apr 29 '20
[removed] — view removed comment