Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

llerajw

macrumors newbie
Original poster
Jan 16, 2010
1
0
I have a MacBook Pro running Mac OS X 10.6.2 and Address Book 5.0.1. With this I'm able to connect Address Book to my company MS Exchange server and have my contacts accessible from my Mac (very nice).

I'm also a Skype user and I got a plug-in script that allows me to trigger a Skype Out call from Address Book. The code this this:

using terms from application "Address Book"
on action property
return "phone"
end action property

on action title for p with e
return "Call using Skype Out"
end action title

on should enable action for p with e
return true
end should enable action

on perform action for p with e
set phone_num to the value of e
skype_out(phone_num)
end perform action

end using terms from

on skype_out(phone_num)
tell application "Skype"
set call_string to "callto:" & phone_num
get URL call_string
end tell
end skype_out

My problem is that this code works for entries in "On My Mac" group (local) but not with my Exchange entries.

To debug the problem I try pulling the properties from the two groups using a simple scrip to try and identify differences. For that I used:

tell application "Address Book"
set thePerson to selection
properties of (item 1 of thePerson)
end tell

When I select an entry in the "On My Mac" group that script runs with no errors and I get what I expected, but when I select an entry in my Exchange group I get this error.

error "Address Book got an error: Can’t get person id \"DC51A134-DD15-47BA-A6D7-62A6286121E9:ABPerson\"." number -1728 from person id "DC51A134-DD15-47BA-A6D7-62A6286121E9:ABPerson"

Can someone help me understand what I'm doing wrong in accessing the entry? Or help me get the plug-in code to work with entries in the exchange group?

Thx

Juan
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.