Hello all,
I typed a simple script to create 6 users for testing another thing in my laptop.
Here is the adsi script
—————————
‘Script to create 6 users in AD( windows 2003)
set objrootdse = getobject (“LDAP://rootdse”)
set objcontainer = getobject(“LDAP://cn=users,” & objrootdse.get(“defaultnamingcontext”))
For i=1 to 6
set objuser = objcontainer.create (“TestUser”,”cn=testuser” & i)
objuser.samaccountname = “testuser” & i
objuser.setinfo
Next
wscript.echo “6 users created”
Th error i get is \\path to script.vbs(7,1)(null) The specified directory attribue or value does not exist. Here i dont any clue why the “objuser.setinfo” is erroring out.
If i remove that line, then script completes without any error, but obviously dont create anything.