Re: Getting a script to run itself recursively
Re: Getting a script to run itself recursively
- Subject: Re: Getting a script to run itself recursively
- From: Philip Aker <email@hidden>
- Date: Sun, 27 May 2007 02:55:36 -0700
On 2007-05-27, at 00:17:01, Jim Witte wrote:
I've got the following script fragment, which tries to get the path
to the current script file, and then tell the Finder to run itself:
set sPath to the path of (item 1 of the document of me)
Jim,
Unless you are writing an AppleScript Studio application, scripts
don't normally have a 'document' class available.
You can run your script in Script Editor because Script Editor has a
'document' class and if the script has been saved, then Script
Editor's document for your script will have a POSIX style 'path'
property. And that's why you can check that the script works in
Script Editor but fails elsewhere.
I believe Matt has given you more than enough info to continue to
success.
Philip Aker
email@hidden
_______________________________________________
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