• 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: Address Book: Getting a reference to email by ID
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Address Book: Getting a reference to email by ID


  • Subject: Re: Address Book: Getting a reference to email by ID
  • From: Matthew Smith <email@hidden>
  • Date: Sat, 12 Apr 2008 00:27:02 +1000
  • Thread-topic: Address Book: Getting a reference to email by ID

on 12/04/2008 00:12 , Michelle Steiner at email@hidden wrote:

> On Apr 11, 2008, at 6:29 AM, Timothy Bates wrote:
>
>> tell application "Address Book"
>> set myGuy to item 1 of (every person whose id is
>> "E28F0E618-55D1-4E37-BC2A-A1D6FCB2B3AE:ABPerson")
>> set x to every email of myGuy whose label is "work"
>> return value of item 1 of x
>> end tell
>
> Observation about scripting style:  I would have written it like this:
>
> tell application "Address Book"
> set myGuy to item 1 of (people whose id is "E28F0E618-55D1-4E37-BC2A-
> A1D6FCB2B3AE:ABPerson")
> return item 1 of (every email of myGuy whose label is "work")
> end tell

Couldn't you say that as:
tell application "Address Book"
 set myGuy to person id "E28F0E618-55D1-4E37-BC2A-A1D6FCB2B3AE:ABPerson"
 return item 1 of (every email of myGuy whose label is "work")
end tell

Why would you say "whose id is..." when you can just refer to the person by
the id?

--
Matthew Smith


 _______________________________________________
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

  • Follow-Ups:
    • Re: Address Book: Getting a reference to email by ID
      • From: Todd Geist <email@hidden>
    • Re: Address Book: Getting a reference to email by ID
      • From: Michelle Steiner <email@hidden>
References: 
 >Re: Address Book: Getting a reference to email by ID (From: Michelle Steiner <email@hidden>)

  • Prev by Date: Re: Address Book: Getting a reference to email by ID
  • Next by Date: Re: Address Book: Getting a reference to email by ID
  • Previous by thread: Re: Address Book: Getting a reference to email by ID
  • Next by thread: Re: Address Book: Getting a reference to email by ID
  • Index(es):
    • Date
    • Thread