cowiekspert
asked on
Create user with vbs in Exchange 2007
Hi
I have the following vbs code that creates a user in AD and adjoining Exchange account. This code has worked fine with Exchange 2003, but with Exchange 2007 the Exchange account that is created is of type legacy and does not work. Help&.
I have the following vbs code that creates a user in AD and adjoining Exchange account. This code has worked fine with Exchange 2003, but with Exchange 2007 the Exchange account that is created is of type legacy and does not work. Help&.
user="nnn"
Set objOU = GetObject("LDAP://cn=users,dc=interconsult,dc=com")
Set objUser = objOU.Create("User", "cn=" & user)
objUser.Put "sAMAccountName",user
objUser.SetInfo
MailServer="ICGTRD241"
MBXStoreDN ="LDAP://CN=Mailbox Database,CN=First Storage Group,CN=InformationStore,CN=" & MailServer & ",CN=Servers,CN=Exchange Administrative Group (FYDIBOHF23SPDLT),CN=Administrative Groups,CN=Interconsult ASA,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=interconsult,DC=com"
Set ExchUser = objUser
ExchUser.CreateMailbox(MBXStoreDN)
ExchUser.SetInfo
objUser.Close
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
any news here?
Like:
http://www.codeguru.com/csharp/csharp/cs_misc/e-mail/article.php/c14009/