How to add extra ou to LDAP script



Hi,
For a few months I've been using a simple script. Now I need to modify
it slightly, but I can't get it to work. I wondered if anybody here
could help. Here's part of the script I'm using at the moment:

Set objGroup = GetObject _
("LDAP://cn=CRMAdmin,ou=myOrgUnit,dc=mycompany-uk,dc=local";)

mycompany-uk.local is my domain name.
myOrgUnit is my organisational unit
CRMAdmin is a security group within myOrgUnit

The change that I want to make is to add another organisational unit
called CRM unit to myOrgUnit, and move CRMAdmin to the lower lever. In
other words I currently have mycompany-uk.local\myOrgUnit\CRMAdmin and
I want to change it to mycompany-uk.local\myOrgUnit\CRM\CRMAdmin

My problem is, how do I make the LDAP line reflect the change? I have
tried the following:

Set objGroup = GetObject _
("LDAP://cn=CRMAdmin,ou=myOrgUnit\CRM,dc=mycompany-uk,dc=local";)

However this doesn't work. Can anybody explain to me what I'm doing
wrong?

Thanks a lot

Colin
.



Relevant Pages

  • Re: How to add extra ou to LDAP script
    ... Here's part of the script I'm using at the moment: ... CRMAdmin is a security group within myOrgUnit ... The change that I want to make is to add another organisational unit ... a child of it's parent ou, and ou=myOrgUnit is a child of the domain. ...
    (microsoft.public.windows.server.scripting)
  • Re: Login scripts based on Organisational Units
    ... the organisational unit the user is assigned. ... creating a conditional script for users is usually based ... the best sample scripts designed to run on Windows 2000, Windows XP, and ... Microsoft Certified Trainer ...
    (microsoft.public.windows.server.general)