RE: Add a domain user group to local computer administrator group
- From: "DataDoug" <DataDoug@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 5 May 2005 13:36:02 -0700
Please see the post w/CNPROGRAMMING group. It does work in AD.
I needed to give students access to the local DEBUGGER USERS group on 32 lab
computers so I created the security group in AD, added the students to the
group and then added the group to the local DEBUGGER USERS group.
I hope this helps and again, sorry for pasting the wrong script earlier.
"MJG" wrote:
> Hi Doug,
>
> Will this work for a active directory domain?
>
> "DataDoug" wrote:
>
> > The following puts domain user BDPA in the local admin group:
> >
> > '*******************************************************************************
> > '* File: AddBDPAUser.vbs
> > '* Purpose: Adds BDPA (domain USer) to local admin group.
> > '*
> > '* Usage: Double Click Script from desired PC to run local or edit
> > strComputer = "." with remote PC name
> > '* Version: 1.0 (22 Oct 04)
> > '* Technology: VBSCRIPT
> > '* Requirements:
> > '* Author: By DataDoug
> > '* History:
> > '*******************************************************************************
> >
> > ' Set the workstation for this action. Replace the "." with a computer name
> > for remote access.
> > strComputer = "."
> >
> > ' Bind to local admin group.
> > Set objGroup = GetObject("WinNT://" & strComputer & "/Administrators,group")
> >
> >
> > ' Bind to domain user BDPA
> > Set objUser = GetObject("WinNT://isd535/BDPA,user")
> >
> > ' Pass path value to local computer
> > objGroup.Add(objUser.ADsPath)
> >
> >
> >
> > "MJG" wrote:
> >
> > > Hi,
> > >
> > > I was wondering if there is a way to script adding a domain user group to
> > > the local administrator group to workstations on our domain. Thanks for you
> > > help.
.
- References:
- Prev by Date: RE: Add a domain user group to local computer administrator group
- Next by Date: Re: WSH code
- Previous by thread: RE: Add a domain user group to local computer administrator group
- Next by thread: RE: Add a domain user group to local computer administrator group
- Index(es):
Relevant Pages
|