cynicaljoy
cynicaljoy

Reputation: 2077

What is the AppleScript Folder Action for moving/deleting a file?

I have a script that is working fine when I add a file to the folder using:

on adding folder items to this_folder after receiving added_items

What is the equivalent when a file is either moved or deleted from that folder?

Thanks!

Upvotes: 0

Views: 1115

Answers (1)

Asmus
Asmus

Reputation: 5247

This should work:

=== edited to answer to comments:

on removing folder items from this_folder after losing lost_items
repeat with i from 1 to number of items in lost_items
    set nameOfLostFile to name of (info for item i of lost_items)
end repeat
end removing folder items from

Upvotes: 2

Related Questions