Re: triggering an AppleScript
Re: triggering an AppleScript
- Subject: Re: triggering an AppleScript
- From: John Delacour <email@hidden>
- Date: Fri, 9 May 2003 21:17:16 +0100
- Mac-eudora-version: 6.0a16
At 2:50 pm -0500 9/5/03, Carl Albrecht-Buehler wrote:
For example, are there ways of dragging and dropping files on top of an
applet that triggers it?
In a word, include an 'open' handler as the top block in the script
and save it save it as APPLICATION. You will see an arrow on the
saved file indicating that it's a droplet.
If it's a task you want to perform regularly, make it stay-open; you
can then drop things on its dock icon and lose no time while it
launches and quits.
Here's a simple example that you can save as above:
on open dropped_items
-- dropped_items is a list of _aliases_
set pathlist to {}
repeat with _alias in dropped_items
set end of pathlist to _alias as Unicode text
end repeat
choose from list pathlist
end open
JD
--
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.