• 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
Address Book – Get the current person's fax number
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Address Book – Get the current person's fax number


  • Subject: Address Book – Get the current person's fax number
  • From: Le Pors Gilles <email@hidden>
  • Date: Tue, 11 Nov 2003 23:08:06 +0100

I'm trying to get the current person's fax number and the best I can come up with, so far, is this:

tell application "Address Book"
set CurrentPerson to the first item of (get the selection)
set ThePhones to the phones of CurrentPerson
repeat with ThisPhone in ThePhones
if label of ThisPhone is "work fax" then
set TheFax to value of ThisPhone
end if
end repeat
display dialog (TheFax)
end tell

It works but it seems very convoluted.

Is there a better way?

Yours Sincerely,

Gilles Le Pors

P.S. Michelle and Paul, thanks for "first item of (get the selection)"
_______________________________________________
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.

  • Follow-Ups:
    • Re: Address Book ­ Get the current person's fax number
      • From: Paul Berkowitz <email@hidden>
  • Prev by Date: Re: AppleScript and Script Editor do not function under 9.2.2 Spanish version
  • Next by Date: Re: Script tell the wrong app !
  • Previous by thread: Page Setup in Acrobat 6, OS X.3
  • Next by thread: Re: Address Book ­ Get the current person's fax number
  • Index(es):
    • Date
    • Thread