Re: script in startup folder
Re: script in startup folder
- Subject: Re: script in startup folder
- From: Kai <email@hidden>
- Date: Wed, 16 Jul 2003 09:45:11 +0100
on Wed, 16 Jul 2003 04:06:11 +0100, I wrote:
>
So instead of:
>
>
>> tell application "Finder"
>
>> select file "Quickstart" of folder "Controlpanels" of folder,
>
>> "Systemfolder" of folder "Teknik" of startup disk
>
>> open selection
>
>> end tell
>
>
...we could just say (all one line):
Sorry Peter - I misread your folder/file hierarchy[1]. As you've probably
already guessed, that would make my suggestions read as follows (each still
one line):
-------------------------
tell application "Finder" to open file "Quickstart" of folder
"Controlpanels" of folder "Systemfolder" of folder "Teknik" of startup disk
-------------------------
tell application "Finder" to open file "Macintosh
HD:Teknik:Systemfolder:Controlpanels:Quickstart"
-------------------------
tell application "Finder" to open file (((path to "ctrl") as string)
& "Quickstart")
-------------------------
The last one will work only for an item called "Quickstart" in your System's
Control Panels folder. If that's not the case (and this is some kind of
non-system path), then you'll need something more like one of the following:
-------------------------
tell application "Finder" to open file (((path to "root") as string)
& "Teknik:Systemfolder:Controlpanels:Quickstart")
-------------------------
tell application "Finder" to open file (startup disk's name
& ":Teknik:Systemfolder:Controlpanels:Quickstart")
-------------------------
[1] One reason I prefer to use paths is that (IMO) they're easier to read
than Finder references.
--
Kai
_______________________________________________
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.