Re: Access to a file via relative path
Re: Access to a file via relative path
- Subject: Re: Access to a file via relative path
- From: Mr Tea <email@hidden>
- Date: Tue, 15 Oct 2002 16:38:34 +0100
This from Markus Wick - dated 15-10-02 02.50 pm:
>
Is thete a way of relative file path access, so i can tell the script
>
somehow to determine its posistion itself, move up one folder, go into
>
folder "filemakerdata" and have access to the "file_to_open"-file ?
If the script has been saved as an application, 'path to me' will give the
location of the script applet, so you could use something like this:
set thePath to path to me
tell application "Finder"
set theFolder to (container of thePath)
set theParentFolder to (container of theFolder)
set fileMakerData to (theParentFolder as string) & "Folder Name" & ":"
set file_to_open to fileMakerData & "File Name" as alias
end tell
This doesn't work with compiled scripts.
HTH
Mr Tea
_______________________________________________
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.