Re: Use of 'path to ... folder creation
Re: Use of 'path to ... folder creation
- Subject: Re: Use of 'path to ... folder creation
- From: Alastair Rankine <email@hidden>
- Date: Sat, 07 May 2005 07:38:02 +1000
Dennis Jones wrote:
Can someone give me an example of how to specify a folder to use and
create the folder if it does not exist.
My script uses ~/my-home/tmp to store a temporary file. I need the
script to create the tmp folder if it does not exist. From reading the
'path to' dictionary entry, it looks to me as if it could take care of
this for me.
Try this:
set home to path to home folder -- or wherever
tell application "Finder"
make new folder at home with properties {name:"temp"}
end tell
Also note there is a temp directory here, may be useful for storing
temporary files:
path to "temp" from user domain
Enjoy.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden