• 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: Search Contacts for phone number
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Search Contacts for phone number


  • Subject: Re: Search Contacts for phone number
  • From: Bill Vlahos <email@hidden>
  • Date: Sat, 27 Sep 2014 14:05:42 -0700

This is pretty neat. I’m actually looking for a whole number and just used the area code as an example.

This seems to work and returns the first name instead of the ID of the record.

tell application "Contacts"
name of first person whose (class of (first phone whose value contains "(805) 555-5555") is phone)
end tell


This returns multiple people but not all of the people that have the number for reasons I don’t understand.

tell application "Contacts"
name of people whose (class of (first phone whose value contains “(805) 555-5555"") is phone)
end tell

Thanks,
Bill Vlahos
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: Search Contacts for phone number
      • From: Christopher Stone <email@hidden>
References: 
 >Search Contacts for phone number (From: Bill Vlahos <email@hidden>)
 >Re: Search Contacts for phone number (From: Axel Luttgens <email@hidden>)
 >Re: Search Contacts for phone number (From: Christopher Stone <email@hidden>)

  • Prev by Date: Re: Search Contacts for phone number
  • Next by Date: Re: Search Contacts for phone number
  • Previous by thread: Re: Search Contacts for phone number
  • Next by thread: Re: Search Contacts for phone number
  • Index(es):
    • Date
    • Thread