• 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: iPhoto and selection
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: iPhoto and selection


  • Subject: Re: iPhoto and selection
  • From: Michelle Steiner <email@hidden>
  • Date: Tue, 30 Mar 2010 18:06:16 -0700

On Mar 30, 2010, at 3:13 PM, Rob Lewis wrote:

Why does this give the error "Can’t make item 1 of selection into type reference."

tell application "iPhoto"
    item 1 of selection
end tell

Use this

tell application "iPhoto"
the selection
item 1 of the result
end tell

or this

tell application "iPhoto"
item 1 of (get the selection)
end tell

or this

tell application "iPhoto"
set foo to the selection
item 1 of foo
end tell

I forget why the implicit "get" doesn't work, requiring one of those workarounds .

-- Michelle

--

"We must believe in free will, we have no choice," -- Isaac Bashevis Singer


 _______________________________________________
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

References: 
 >iPhoto and selection (From: Rob Lewis <email@hidden>)

  • Prev by Date: Re: Different pictures into one document
  • Next by Date: Re: Read/Write Text Files
  • Previous by thread: iPhoto and selection
  • Next by thread: Fw: Read Write Text File
  • Index(es):
    • Date
    • Thread