Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Applescript > Searching Addre...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 3 Topic 1567 of 1612
Post > Topic >>

Searching Address Book for Fax numbers

by John Mosby <johnsmosby@[EMAIL PROTECTED] > Feb 2, 2008 at 09:21 AM

The script below fails on the "set thelabel to label of phone"  with
the error "can't get label of phone".  How do I get the value of the
label of the phone entries?  Thanks.

tell application "Address Book"
	make new group with properties {name:"pharmacy with fax"}
	repeat with eachContact in (get every person in group "Pharmacy") --
(get every person)
		repeat with eachPhoneNum in (get phones of eachContact)

			set thelabel to label of phone
			set thevalue to value of phone


			-- check to see if label contains "fax"

			if thelabel contains "fax" then
				add eachContact to group "pharmacy with fax"
			end if
		end repeat
	end repeat
	save addressbook
end tell




 3 Posts in Topic:
Searching Address Book for Fax numbers
John Mosby <johnsmosby  2008-02-02 09:21:35 
Private Message
   2008-02-02 11:31:34 
Re: Searching Address Book for Fax numbers
John Mosby <johnsmosby  2008-02-02 11:21:55 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat May 17 13:39:37 CDT 2008.