local administrator user

A

ali paracha

sir
i want a group policy script to create a adinistrator
local user but this should be applied in domian group
plicy so that i create local user on 200 computer at the
same time with same password.
thx
 
N

Niclas Lindblom

Running a script at startup with code similar to below, should give you the
neccesary permissions to create this account.

**SCRIP START
Dim oPC
Dim oGroup
Dim oWshNetwork
Dim oUser

Set oWshNetwork=CreateObject("wscript.network")
Set oPC=getObject("WinNT://" & oWshNetwork.ComputerName)
Set oGroup=GetObject("WinNT://" & oWshNetwork.ComputerName &
"/Administrators",Group)

Set oUser=oPC.create("User","myAdminUserName")
oUser.setpassword "MyPassword"
oUser.setinfo
oGroup.add(oUser.adspath)
oGroup.setinfo
**SCRIPT END

Hope this helps

Regards

Niclas Lindblom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top