|
server
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
exporting * importing users into groupsHi,
I am wanting to export a list of usernames from an AD group & then import them back into another group. I believe it is possible to do this using the csvde command, but Im not sure of the syntax. Would some one be kind enough to explain what syntax I would use for both of these tasks please? Thanks -- pljdoyle ------------------------------------------------------------------------ pljdoyle's Profile: http://forums.techarena.in/members/pljdoyle.htm View this thread: http://forums.techarena.in/server-scripting/1084621.htmhttp://forums.techarena.in pljdoyle wrote:
> I am wanting to export a list of usernames from an AD group & then A VBScript solution would be similar to:> import them back into another group. I believe it is possible to do > this using the csvde command, but Im not sure of the syntax. Would some > one be kind enough to explain what syntax I would use for both of these > tasks please? > > Thanks =========== ' Bind to "source" group. Set objGroup1 = GetObject("LDAP://cn=Source Group,ou=West,dc=MyDomain,dc=com") ' Bind to "target" group. Set objGroup2 = GetObject("LDAP://cn=Target Group,ou=West,dc=MyDomain,dc=com") ' Enumerate direct members of "source" group. For Each objMember In objGroup1.Members ' Check if this object is already a member of "target" group. If (objGroup2.IsMember(objMember.AdsPath) = False) Then ' Make a member of "target" group. objGroup2.Add(objMember.AdsPath) Then Next You could do this with my Bulk Password Control/Bulk AD Users tool:
http://www.wisesoft.co.uk/Products/PasswordControl/BulkPasswordControl/ Just select the users from the old group and then use the bulk modify dialog to append the new group. Hope this helps, David http://www.wisesoft.co.uk (My personal website and a free resource for IT Professionals) PS A new version of the application called "Bulk AD Users" is available as beta for testing purposes: http://www.wisesoft.co.uk/articles/bulk_ad_users_beta_testing.aspx Show quoteHide quote "pljdoyle" <pljdoyle.3k8yxa@DoNotSpam.com> wrote in message news:pljdoyle.3k8yxa@DoNotSpam.com... > > Hi, > I am wanting to export a list of usernames from an AD group & then > import them back into another group. I believe it is possible to do > this using the csvde command, but Im not sure of the syntax. Would some > one be kind enough to explain what syntax I would use for both of these > tasks please? > > Thanks > > > -- > pljdoyle > ------------------------------------------------------------------------ > pljdoyle's Profile: http://forums.techarena.in/members/pljdoyle.htm > View this thread: http://forums.techarena.in/server-scripting/1084621.htm > > http://forums.techarena.in >
What is error '80041003', please?
How can I do a WMI Bulk data retrieval ? Is there any way to control the Transport Server (subcomponent of Windows Deployment Services) via P DISKPART select command doesn't have a "noerr" command for scripti Net send over different domains Problem calling oADsSecurityUtility.SetSecurityDescriptor from VBScript Monitor Folder Recursively using WMI script to extract and create contacts How to Modify AD CN Field can I do this from answer file or do I need to script post install? |
|||||||||||||||||||||||