This is exchange server based Windows Messenger and is the 5.0 version of
the exchange server windows messenger
The script I wrote below gathers the names of the users in my organization
with instant messenger enabled and then adds the users to the contact list
in the registry. If I run it, it adds all the users in the organization
into the messenger contact list. However, like I said, it doesn't update
the users status (ie when they go offline and online). The users do get
updated when I log off and on again.
And I know the script is working as far as interacting with the exchange
server since the registry only has the users e-mail address and my contact
list shows the full name of the user in active directory.
Set WshShell= WScript.CreateObject("Wscript.Shell")
Set wnet=CreateObject("Wscript.Network")
strUsername= wnet.username
Set ObjOU= GetObject("LDAP://ou=staff,DC=baltimorebehavioralhealth,DC=org")
For Each ObjUser In ObjOU
If ObjUser.msexchIMaddress <> "" then
strreg=
"HKCU\Software\Microsoft\Exchange\Messenger\Profiles\
http://bbhtx.org/instms
g/aliases/" & strusername & "\Contacts\"
strKey= strreg & objUser.msexchIMaddress
WshShell.RegWrite strKey, objUser.msexchIMaddress
end if
next