Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

cmiorio

macrumors newbie
Original poster
Mar 18, 2009
1
0
I want to write an applescript that, when adding a file to a folder, creates a copy of that file at a specific location. I enabled Folder Actions for my folder and assigned it the following script :


on adding folder items to this_folder after receiving added_items

say "Script started"

tell application "Finder"
duplicate added_items to "/Users/Chris/Desktop/test"
end tell

beep 2

end adding folder items to



When I add a file to my folder, say "Script started" is executed, but the script stops there. However, if I change "/Users/Chris/Desktop/test" to desktop without anything else, the script works. The script also works if I write duplicate added_items to this_folder

What's wrong with my folder path???

Thanks!
P.S.
I'm running OS 10.5.6
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.