• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: What type is the finder selection?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What type is the finder selection?


  • Subject: Re: What type is the finder selection?
  • From: Michelle Steiner <email@hidden>
  • Date: Mon, 12 Aug 2002 13:53:19 -0700

On Monday, August 12, 2002, at 01:21 PM, Doug McNutt wrote:

"selection" returns a list of the items currently selected in the finder. How can I tell if they are disks, folders, or files?

ell application "Finder"
class of item 1 of (the selection as list)
end tell

In OS X, selection is a property, even though it looks like a list, so you have to coerce it as a list before getting an item.

In your example (disk "Hubble") disk is not a word; it is a class name. It is not inside quotes.

--Michelle

We're not human beings having a spiritual experience.
We're spiritual beings having a human experience.
_______________________________________________
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.

References: 
 >What type is the finder selection? (From: Doug McNutt <email@hidden>)

  • Prev by Date: Indesign Applescript wizard anywhere
  • Next by Date: 1.8.3
  • Previous by thread: What type is the finder selection?
  • Next by thread: Re: What type is the finder selection?
  • Index(es):
    • Date
    • Thread