Hi all,
I am trying to populate this field using my code.
But when I do I only see this for example
fpachon
under the user logon name under the accout tab
When I create a user manullly using Active Directory Users Computers, I see
mpachon
and the next field already has the @domain prefilled.
Can someone help me sort this out.
Thanks.
wscript.Echo "First Name: " & user_array(0)
new_str = left(user_array(0),1)
wscript.Echo "userPrincipalName = " & new_str & user_array(1)
Set objUser = objOU.Create("User", "cn=" & user_array(0) & user_array(1))
objUser.Put "sAMAccountName","" & user_array(0) & user_array(1)
objUser.Put "userPrincipalName","" & new_str & user_array(1)
objUser.SetInfo
I am trying to populate this field using my code.
But when I do I only see this for example
fpachon
under the user logon name under the accout tab
When I create a user manullly using Active Directory Users Computers, I see
mpachon
and the next field already has the @domain prefilled.
Can someone help me sort this out.
Thanks.
wscript.Echo "First Name: " & user_array(0)
new_str = left(user_array(0),1)
wscript.Echo "userPrincipalName = " & new_str & user_array(1)
Set objUser = objOU.Create("User", "cn=" & user_array(0) & user_array(1))
objUser.Put "sAMAccountName","" & user_array(0) & user_array(1)
objUser.Put "userPrincipalName","" & new_str & user_array(1)
objUser.SetInfo