Finding the disk name
Sarah
sarahr at genesearch.com.au
Wed Aug 27 22:02:00 EDT 2003
In the newer version of Revolution, running under OS X, when I get a
file name (say from answer file), I get something like this:
/Users/sarah/Documents/FolderName/Filename.txt
This is fine and Rev reads such a file perfectly. The problem arises
when I want to pass a filename to an AppleScript, which requires a full
path including the disk name, in this form:
Sarah HD:Users:sarah:Documents:FolderName:Filename.txt
So far I have been cheating and just getting "line 1 of the volumes"
and adding that to the start of the Rev file path, but I can foresee
problems.
- Is the first line of the volumes always the startup disk?
- If the path is on a network drive, I can check for the word "Volumes"
at the beginning and find the drive name after that, but what about a
partition. Does anyone have a script that can give me the parent drive
of any given file?
Cheers,
Sarah
sarahr at genesearch.com.au
http://www.troz.net/Rev/
More information about the use-livecode
mailing list