Re: (no subject)
Re: (no subject)
- Subject: Re: (no subject)
- From: Michelle Steiner <email@hidden>
- Date: Sun, 28 May 2006 18:08:42 -0700
On May 28, 2006, at 5:51 PM, Robert Poland wrote:
tell application "Finder"
if selection is not {} or selection is not "" then
beep
end if
end tell
When run from Smile with nothing selected in the Finder the above
yields a beep.
Am I missing something?
Yes; the selection is never "", so the statement is always true.
I don't know why you have 'or selection is not "' there in the first
place; a finder selection is always a property (but looks like a
list). It is never a string.
If you replace "or" with "and" it will not beep if nothing is
selected, and will be if anything is selected because 'or selection
is not "' is always true.
-- Michelle
--
I'm at an age where I can satisfy my wants without too many guilt
feelings.
_______________________________________________
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
References: | |
| >(no subject) (From: Robert Poland <email@hidden>) |