Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

80070005 Active Directory: General access denied error

Status
Not open for further replies.

vami

IS-IT--Management
Joined
Oct 29, 2003
Messages
1
Location
DE
Hi there,

I'm trying to write a script to put the username into the computer object on user logon. (will be called from logon script later)
Unfortunately I get an error saying 80070005 Active Directory: General access denied error
If fails on the last line objComp.SetInfo (of course)

Here's my code:

Set objSysInfo = CreateObject("ADSystemInfo")
Set objComp = GetObject("LDAP://"& objSysInfo.ComputerName)
Set objUser = GetObject("LDAP://"& objSysInfo.UserName)
objComp.put "Description", objUser.displayname
objComp.SetInfo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top