Re: Mac OS X Finder views
Re: Mac OS X Finder views
- Subject: Re: Mac OS X Finder views
- From: Paul Berkowitz <email@hidden>
- Date: Fri, 02 Aug 2002 17:34:06 -0700
On 8/2/02 5:03 PM, "Darin Ames" <email@hidden> wrote:
>
> Somewhat in keeping with this thread, I could use a bit of help with a
>
> script to se the front most window to Icon View AND the Global View for icon
>
> view.
>
>
>
> What I have so far is...
>
>
>
> tell window 1 of application "Finder"
>
> set current view to icon view
>
> set arrangement to globaliconpreference
>
> end tell
>
>
>
> But it gets stuck.
>
>
If you're using the 'tell' syntax, rather than the specific 'of someObject'
syntax, you often need to throw in an 'its' so the application is not
confused by whose properties you're referring to. So it proves in this case.
As well, 'arrangement' is not a property of the window - it's a property of
the 'icon view options' of the window. Finally, i have no idea what that
'globaliconpreference' variable is, but if you defined it previously in a
Finder tell block using one of the legitimate constants for 'icon view
options' as found in the Finder dictionary (in OS X, it's to be found in the
Legacy Suite), you'll be OK:
tell application "Finder"
set globaliconpreference to snap to grid -- for example
tell window 1
set current view to icon view
set arrangement of its icon view options to globaliconpreference
end tell
end tell
--
Paul Berkowitz
_______________________________________________
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.