Re: Variable reference to a file...
Re: Variable reference to a file...
- Subject: Re: Variable reference to a file...
- From: "Marc K. Myers" <email@hidden>
- Date: Sun, 04 Feb 2001 13:45:02 -0500
- Organization: [very little]
giZm0 wrote:
>
Date: Sat, 03 Feb 2001 17:20:07 -0500
>
Subject: Variable reference to a file...
>
From: giZm0 <email@hidden>
>
To: Applescript Mailing List <email@hidden>
>
>
Hi,
>
i would like to refer to file from the application ircle.
>
>
But since my script will be distibuted to sevral computers, i need to make
>
sure the file will be found even if the file's path changes. The best would
>
be that the file sits is in the app's folder....
>
>
now, can i specify a path that would look in the current app (ircle)'s
>
folder and look for the file ? ex: file "<path to the app's
>
folder>:file.txt" ?
It's very easy if you know ircle's creator code. For this example,
let's say it's "IRCL" and the file's name is "myFile":
tell application "Finder"
set myFldr to (container of (application file ID "IRCL")) as text
if exists file (myFldr & "myFile") then
display dialog "It's here!"
end if
end tell
Marc K. Myers <email@hidden>
http://AppleScriptsToGo.com
4020 W.220th St.
Fairview Park, OH 44126
(440) 331-1074
[2/4/01 1:44:16 PM]