Re: Strange error...
Re: Strange error...
- Subject: Re: Strange error...
- From: Emmanuel <email@hidden>
- Date: Fri, 5 Aug 2005 20:20:37 +0200
At 10:53 AM -0700 8/5/05, Glenn Sugden wrote:
Tell Application "Finder"
set winLeft to item 1 of (bounds of first window)
End Tell
Results in: Finder got an error: Can't get item 1 of bounds of window 1.
FWIW, so does: set winLeft to (item 1 of (bounds of first window))
What the heck am I missing here?
It is because what you really want is that Finder get the bounds of
window 1, and then that AppleScript extract the first item of that
quantity. Here you are asking Finder to resolve the whole descriptor
"first item of the bounds of the first window". Just force the
evaluation of the intermediate quantity with "get".
More lines on this issue at:
<http://www.satimage-software.com/en/gotchas.html> (To get or not to get)
Emmanuel
_______________________________________________
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