Sign in to follow this  
Followers 0
flitcraft33

Office Communicator Com Object

4 posts in this topic

Ok, total n00b needs help here.

I am trying to write a com script for Communicator 2007 to send a message with a single mouse click. I don't want to hunt down an active window and do it that way, I want to create an instance of it and use the com interface to blast out a message.

I CANNOT for the life of me find the name for the class name for the Com object for Communicator to use in an ObjCreate() function call.

Can some kind soul point me in the right direction? I have been sifting through the Microsoft API stuff and google and OLEVIEW all day with no luck.

I need some help, please

Thanks very much,

Dan Sichel

flitcraft33

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Hello Dan Sichel!

Class name:

"Communicator.UIAutomation"

(At least, this is what I've found in MSDN site)

Example:

$oCommunicator = ObjCreate("Communicator.UIAutomation")
$MyName = $oCommunicator.MyFriendlyName
$MyLogin = $oCommunicator.MySigninName
MsgBox(0, 'Example', 'Hi!' & @CR & 'My name is "' & $MyName & '" (e-mail: ' & $MyLogin & ')')

MSDN and Google are your best friends in this case! ;)

Edited by SeF

Share this post


Link to post
Share on other sites

Example:

$oCommunicator = ObjCreate("Communicator.UIAutomation")
$MyName = $oCommunicator.MyFriendlyName
$MyLogin = $oCommunicator.MySigninName
MsgBox(0, 'Example', 'Hi!' & @CR & 'My name is "' & $MyName & '" (e-mail: ' & $MyLogin & ')')

Thank you very much for replying. I had seen something similar at MSDN and I tried this, but got an error that said,

Variable must be of type "Object".:$MyName = $oCommunicator.MyFriendlyName

Your reply was very helpful, I now know this SHOULD work.

I was thinking I was doing it totally wrong with this method. I still get the error, but now I am wondering if I have not installed the API correctly or whether I need to register some DLL or something. When I use OLEVIEW I cannot find a Communicator.UIAutomation object or anything even close. I tried to read about installing the API and SDK for Communicator but I couldn't find much besides download and install the API which I did. Most Microsoft discussion seems focused (surprise) on Visual Studio users.

So I am still scratching my head and trying to get this to work. Any further suggestions about what is missing in my environment would be appreciated. I have Communicator 2007 installed and working on my Windows 7 machine, and I did run the API installion, but still no objects and no worky. Thanks again for the assistance on this.

Dan Sichel.

Share this post


Link to post
Share on other sites

Happy days!

I re-downloaded the SDK and reinstalled, started communicator, and it worked like a charm.

Oddly, oleview still doesn't see the objects, but I am on my way.

Thanks very much for the help.

Dan S.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0