Re: new to OSX
Re: new to OSX
- Subject: Re: new to OSX
- From: Andrew Oliver <email@hidden>
- Date: Thu, 11 Sep 2003 15:13:04 -0700
You either need to be much more specific in telling the Finder what to do,
or be more direct.
'select folder "untitled folder"' doesn't help the Finder know where to find
the folder. On the disk root is where I'd expect it to start, but that's no
guarantee. Also, if you're working on a non-US OS it probably won't be
called 'untitled folder" so your code will break anyway.
Finally, selecting the folder and changing the name of the selection is
about the worst way you can do this (I know, it's how it was recorded by the
old Finder), but it relies on the user not doing anything else while the
script is running. If your script selects the folder and then the user
clicks somewhere else in the time it takes to move to the next statement,
your code will break.
Either track the newly-created folder and set its name:
set myNewFolder to make new folder at desktop
set name of myNewFolder to job_number
Or, even better, name the folder as it's created:
make new folder at desktop with properties {name: job_number}
This latter form is fastest, and doesn't rely on the selection at all.
As for the recording question, I point you in the direction of Apple's Bug
Reporter where you can file a bug report/feature request.
Andrew
:)
On 9/11/03 2:48 PM, "David DuBois" <email@hidden> wrote:
>
I have a simple script that I use a lot in OS 9, and I have finally made the
>
move to OSX and it no longer works. Simply put, I used to create a folder on
>
the desktop and modify the name of it. I used:
>
>
make new folder at desktop
>
select folder "untitled folder"
>
set name of selection to job_number
>
>
In OSX it will make the folder on the desktop, but then it will no longer
>
select that new folder. What do I need to do differently?
>
>
Also, prior to OSX finder used to be recordable, but it doesn't seem to be any
>
longer, can any one point me the right way?
>
>
Thanks
>
David
>
_______________________________________________
>
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.
_______________________________________________
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.