Re: Addressing the folder that contains an item
Re: Addressing the folder that contains an item
- Subject: Re: Addressing the folder that contains an item
- From: Rob Jorgensen <email@hidden>
- Date: Tue, 17 Sep 2002 13:45:05 -0400
On 9/17/02, Chad Chelius commented:
I am trying to figure out how to create a folder in the parent directory of
an item. For instance if I have a variable MyDirectory that contains the
path to a specific folder, how can I create a folder in the directory that
contains MyDirectory? MyDirectory is "Macintosh HD:Users:Chad:Temp" but I
want to create a new folder in the Chad folder based on my variable
MyDirectory. Thanks in advance.
This might work (tested with Jaguar):
tell application "Finder" to set newFol to make new folder of
container of MyDirectory with properties {name:"Chad Sibling Folder"}
All one line - watch for email line wraps.
newFol will contain a Finder reference to the new folder.
--
Rob Jorgensen
Ohio, USA
_______________________________________________
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.