Re: Folder name from alias
Re: Folder name from alias
- Subject: Re: Folder name from alias
- From: "Marc K. Myers" <email@hidden>
- Date: Fri, 08 Dec 2000 11:32:21 -0500
- Organization: [very little]
Rick Plummer wrote:
>
Date: Thu, 07 Dec 2000 23:48:26 -0600
>
From: Rick Plummer <email@hidden>
>
To: email@hidden
>
Subject: Folder name from alias
>
>
I need script that will extract the folder name of a folder
>
dropped on an applet (for use later inthe script).
>
>
e.g.:
>
on open x
>
tell application "Finder"
>
yada
>
yada
>
make new folder at (location) with properties
>
{name:<folder name from x>}
on open (itemList)
set fldrPath to (item 1 of itemList) as text
set {oldDelims, AppleScript's text item delimiters} to [optn-L]
{AppleScript's text item delimiters, ":"}
set theName to text item -2 of fldrPath
set AppleScript's text item delimiters to oldDelims
tell application "Finder"
make new folder at <location> [optn-L]
with properties {name:theName}
end tell
end open
Note to group: How about using "[optn-L]" in place of the continuation character?
Marc [12/8/00 11:29:51 AM]