Moving objects Active Directory

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: André Möller (andre-moller_at_procergs.rs.gov.br)
Date: 05/31/04


Date: Mon, 31 May 2004 10:13:09 -0300

Hello, I would like to develop a script that moves a computer account from
"CN=Computers" for "OU=Workstations" but my problem is that the name of
computer couldn't be assigned because I would like to move daily every
workstations for new OU. (workstation names allways begins by "ws-")

Is the script that I have tried:

Set objNewOU = GetObject("LDAP://OU=Teste,DC=WORKGROUP")
Set objMoveComputer = objNewOU.MoveHere _
    ("LDAP://CN=%ws-%,CN=Computers,DC=WORKGROUP", "cn=%ws-%")

If someone knows, tell me.

Tks.
André Möller
PROCERGS - Divisão de Redes
Administração de Redes e Softwares - Grupo Windows
Fone: 55-51-3210-3108



Relevant Pages

  • VBScript and foreign languages
    ... I have a VBScript to help users create computer accounts in Active Directory ... The script is using alternate domain ID with privilege to create ... computer account in domain using OpenDSObject. ... Sub CreateComputer ...
    (microsoft.public.scripting.vbscript)
  • Re: VBScript and foreign languages
    ... The only time I've seen problems has been assigning permissions to trustees. ... The script is using alternate domain ID with privilege to create ... > computer account in domain using OpenDSObject. ... > Sub CreateComputer ...
    (microsoft.public.scripting.vbscript)
  • Login Script to Install Printers Based on Computer Group
    ... computer based on what group the computer account was in. ... originally had the printers installed via a login script when the user ... Dim objNetwork, objSysInfo, strUserDN ... Call LoadGroups(objPriObject, objGroup) ...
    (microsoft.public.win2000.active_directory)
  • Re: Disable/Delete unused workstations
    ... This script will remove inactive machine accounts in Active Directory ... > is there a way to automatically disable or delete workstations not used in ...
    (microsoft.public.win2000.group_policy)
  • Re: Deploying Red Hat Workstations
    ... > can easily make changes to the workstations all at once. ... Have the central server push out to each host. ... > This script will contain any changes that I need to make. ... I would automate SCP from the server to a user account (not ...
    (Fedora)