Skip to content

My first AppleScript: Copy Address Book entries

2007 May 10
by tobi

Tatataa! I just wrote my frist AppleScript. For displaying the buddypicture of my Address Book contacts in Adium, I had to copy the ICQ entry to a new Jabber enrty with appending “@jit.jabber.fsinf.de”. The code follows:

[bash]
tell application "Address Book"
set thePeople to every person whose ICQ handles is not {} and Jabber handles is {}
repeat with eachPerson in thePeople
set icqnr to value of ICQ handles of eachPerson
set jabberid to (item 1 of icqnr) & "@jit.jabber.fsinf.de"
make new Jabber handle at end of Jabber handles of eachPerson with properties {label:"Home", value:jabberid}
end repeat
save addressbook
end tell
[/bash]

It worked out fine. Now I see you all in my buddylist 😉

Flattr this!

One Response

Trackbacks and Pingbacks

  1. My first AppleScript: Copy Address Book entries | Lustauffotos.de

Comments are closed.