Re: Is finder brain dead?
Re: Is finder brain dead?
- Subject: Re: Is finder brain dead?
- From: Robert Poland <email@hidden>
- Date: Thu, 08 Dec 2011 12:55:00 -0700
Thanks Luther,
Seems like I've been here before. List caught me again.
On Dec 8, 2011, at 12:48 PM, Luther Fuller wrote: On Dec 8, 2011, at 12:21 PM, Robert Poland wrote: I have a script that uses the following;
tell application "Finder" delay 10 set selected_Item to selection delay 10 display dialog "" & selected_Item end tell
If I open, for example, the Applications folder and select any item then run the script "selected_Item" is empty. If I run the script again all is well.
That's because selected_Item is a list. This WILL work ...
tell application "Finder" set selList to selection if (count items of selList) ≠ 1 then return set selItem to (item 1 of selList) as alias display dialog selItem as text end tell
Robert Poland - Fort Collins, CO
|
_______________________________________________
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