Re: Slight deviation, big problem with script
Re: Slight deviation, big problem with script
- Subject: Re: Slight deviation, big problem with script
- From: Luther Fuller <email@hidden>
- Date: Mon, 23 May 2011 11:21:18 -0500
On May 23, 2011, at 10:56 AM, Jeffrey Madson wrote: I have attached a script below that works great and has been used extensively. Instead of installing the RRDAuto folder into the Utilities folder I want to install it into a folder called "Options" at the top level of the hard drive now. The "Options folder may or may not already exist when this is run.
In the first line I took out the word utilities and put in Options folder which creates an error. I also changed the set folderpath to line to: set folderpath to (("Options")) as text) & "RRDAuto" but the script never gets that far.
Any suggestions on how to get this script corrected would be greatly appreciated.
-- create RRDAuto folder set x to path to utilities folder
There is no 'path to options folder'. You have to do this ...
property startupAlias : (path to startup disk) property optionsName : "Options" property RRDAutoName : "RRDAuto"
tell application "Finder" if not (exists folder optionsName of startupAlias) then make new folder at startupAlias with properties {name:optionsName} end if set optionsAlias to (folder optionsName of startupAlias) as alias end tell
Then for this bit of script ...
-- the folder which should get an icon set folderpath to (("Applications:Utilities:") as text) & "RRDAuto" set folderpath to quoted form of POSIX path of folderpath
do the same thing ...
tell application "Finder" if not (exists folder RRDAutoName of optionsAlias) then make new folder at optionsAlias with properties {name:RRDAutoName} end if set RRDAutoAlias to (folder RRDAutoName of optionsAlias) as alias set folderpath to (quoted form of (POSIX path of RRDAutoAlias)) end tell
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden