I’ve been attempting this for a long time, and I just can’t seem to figure it out. Plus, since AppleScript has a function called “Droplet” (like Photoshop), when I try to search I get bogged down by inaccuracies.
I have a Photoshop and an ImageReady Droplet that resize some images, add some effects and save them. All I want to do is, when some places a file/folder in the Images folder, to have that file/folder run through the droplet.
Since it isn’t recognized as an Application, I have been toying with the open command within Finder’s Dictionary. I can get the Droplet to open, but I can’t get it to automatically run on the folder/file.
Typically, to make a droplet work, you drag a file onto it. Is there a specific command I should be looking for?
If you attach this script to the drop folder as a folder action, it might do what you want to do.
on adding folder items to this_folder after receiving added_items
tell application "Finder" to open added_items using "path:to:droplet"
end adding folder items to
Well, that worked fine for running the droplet, but now the rest of the script won’t work. Basically, this is supposed to take a folder of images, make them website ready, copy the folder to temp, rename that to thumb and then copy that folder back into the original (then, later, that thumb file will get another script run on it)
Basically, with the following script, it just stops after it runs the ImageResize droplet. it doesn’t continue with the other part that I know works. Any ideas?
Appreciate it,
Nate
property dialog_timeout : 30
property TempDir : "Macintosh HD:Users:admin:Desktop:ImageGallery:temp:"
property TempDirThumb : "Macintosh HD:Users:admin:Desktop:ImageGallery:temp:thumb:"
on adding folder items to this_folder after receiving AddedImages
try
tell application "Finder"
set the NewFolder to item 1 of the AddedImages
set the NewFolderName to the name of NewFolder
end tell
tell application "Finder" to open NewFolder using "Macintosh HD:Applications:ImageResize"
tell application "Finder"
delete TempDirThumb
set ThumbNailFolder to duplicate NewFolder to TempDir
--set ThumbNailFolder to duplicate NewFolder to TempDir with replacing
set name of ThumbNailFolder to "thumb"
move TempDirThumb to NewFolder with replacing
end tell
end try
end adding folder items to
property dialog_timeout : 30
property TempDir : "Macintosh HD:Users:admin:Desktop:ImageGallery:temp:"
property TempDirThumb : "Macintosh HD:Users:admin:Desktop:ImageGallery:temp:thumb:"
on adding folder items to this_folder after receiving AddedImages
try
tell application "Finder"
set the NewFolder to item 1 of the AddedImages
set the NewFolderName to the name of NewFolder
open NewFolder using "Macintosh HD:Applications:ImageResize"
delete folder TempDirThumb
set ThumbNailFolder to duplicate NewFolder to folder TempDir
--set ThumbNailFolder to duplicate NewFolder to TempDir with replacing
set name of ThumbNailFolder to "thumb"
move folder TempDirThumb to NewFolder with replacing
end tell
end try
end adding folder items to