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

Re: maddening


  • Subject: Re: maddening
  • From: Matthew Smith <email@hidden>
  • Date: Tue, 28 Jun 2005 12:32:09 +1000

on 28/06/2005 12:23, Matthew Smith at email@hidden wrote:

> on 28/06/2005 12:09, doug rogers at email@hidden wrote:
>
>> I get
>>
>> NSReceiverEvaluationScriptError (4)
>>
>> with the word 'return' selected in this script in Script Editor
>>
>> tell application "Address Book"
>> activate
>> set FoundAddress to (get (street of address of person FindThis) &
>> return & ¬
>> (city of address of person FindThis) & (state of address of person
>> FindThis) & return & ¬
>> (country of address of person FindThis) & (zip of address of person
>> FindThis))
>> end tell
>
> You don't say what version you are on. It works for me on Tiger once I put the
> following line in front of it all:
>
> Set FindThis to "Matthew Smith"
>
> Of course the results are not good. There is more than one address for me. I
> get a list of items. Doing a 'get (street of address of person FindThis)'
> returns a list of 2 items. If I change it to 'get (street of address 1 of
> person FindThis)' I do not. You are also missing spaces between city and
> state, as well as country and zip.

I am not sure about previous versions of Mac OS X but on Tiger you can do it
this way, if you want the way Address Book will format it:

set FindThis to "Matthew Smith"
tell application "Address Book"
  set FoundAddress to get (formatted address of address 1 of person
FindThis)
end tell


--
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:

This email sent to email@hidden

References: 
 >Re: maddening (From: Matthew Smith <email@hidden>)

  • Prev by Date: Re: maddening
  • Next by Date: Re: Any suggestions for scheduling one off jobs?
  • Previous by thread: Re: maddening
  • Next by thread: re: maddening
  • Index(es):
    • Date
    • Thread