getting contacts from entourage
getting contacts from entourage
- Subject: getting contacts from entourage
- From: Malcolm Fitzgerald <email@hidden>
- Date: Fri, 26 Mar 2004 13:08:58 +1100
I have to dump the contents of an entourage address book into a tab
separated file.
It's easy to loop through the address book looking at each contact
but it seems slow and I'd like to speed it up. I'd also like to be
able to ask Entourage to filter records using categories, eg, every
contact whose category includes "Full Member"
Right now I can go to every contact and get it's properties one by
one. This means over a dozen calls for each contact. Is there a way
to get everything in one shot ?
This is what I'm doing right now:
-- <script>
set tabSepList to {}
set my text item delimiters to tab
tell application "Microsoft Entourage"
repeat with i from 1 to 4 -- ( count contacts )
set myContact to {}
tell contact i to get it's category
if the result contains {category id 5} then
tell contact i
set end of myContact to first name
set end of myContact to last name
set end of myContact to city of home address
set end of myContact to state of home address
set end of myContact to zip of home address
-- etc for the rest of the properties
end tell
end if
set end of tabSepList to myContact as Unicode text
end repeat
end tell
set my text item delimiters to return
tabSepList as unicode text
-- </script>
Any improvements gratefully accepted.
--
--
Malcolm Fitzgerald email@hidden
Database Manager
http://www.asauthors.org
The Australian Society of Authors ph: 02 93180877 fax: 02 93180530
_______________________________________________
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.