• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: folder actions
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: folder actions


  • Subject: Re: folder actions
  • From: Wayne Melrose <email@hidden>
  • Date: Tue, 9 Oct 2007 15:44:53 +0200


On 09/10/2007, at 3:17 PM, Axel Luttgens wrote:

As I was wondering whether "they" had dared to change something since last time I checked Folder Actions, I quickly devised a small test along the lines of your first email (the one that opened this thread).


So, let's have a one-liner script:


   display dialog "I've just been added to folder AddHere!"


saved as "ScriptToBeAdded.scpt" on the Desktop.


Let's also have a slightly more complicated script:


   on adding folder items to this_folder after receiving added_items

       run script (item 1 of added_items)

   end adding folder items to


saved as "InvokedOnAdding.scpt" in folder ~/Library/Scripts/Folder Action Script.


Now, let's create folder "AddHere" on the Desktop, attach script "InvokedOnAdding.scpt" to it and finally move "ScriptToBeAdded.scpt" over it.

The expected dialog box appears:


   I've just been added to folder AddHere!


so that Folder Actions still seem to be with us...


Of course, with above very bare scripts, no need to have a tell block targeting the Finder or System Events.

How do your scripts differ from the above ones, so that they seemingly need such a tell block?



Thanks for the reply.. sorry for my delay.. Let's start with the basics as you did.. 

Why can't I get even this to work ? 

on adding folder items to this_folder after receiving added_items


-- repeat with each added item
repeat with i from 1 to count items of added_items
set scptProductionScript to item i of added_items
display dialog scptProductionScript


end repeat
end adding folder items to



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: folder actions
      • From: James Nierodzik <email@hidden>
    • Re: folder actions
      • From: Axel Luttgens <email@hidden>
References: 
 >folder actions (From: Wayne Melrose <email@hidden>)
 >Re: folder actions (From: KOENIG Yvan <email@hidden>)
 >Re: folder actions (From: Wayne Melrose <email@hidden>)
 >Re: folder actions (From: Axel Luttgens <email@hidden>)
 >Re: folder actions (From: Wayne Melrose <email@hidden>)
 >Re: folder actions (From: Axel Luttgens <email@hidden>)

  • Prev by Date: Re: Trouble with Remote Apple Events (eppc) and Keychain
  • Next by Date: Re: folder actions
  • Previous by thread: Re: folder actions
  • Next by thread: Re: folder actions
  • Index(es):
    • Date
    • Thread