List Group Members in txt file problem

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



I'm running this portion of a script to list the members of a group that are
computers, there are over 1500 members, when I run it I dion't get all the
members in the txt file.

Any ideas?

Set FSO = CreateObject("Scripting.FileSystemObject")
Set readout =
FSO.OpenTextFile_("\\server\installs$\USBmembers\computers.txt",2,True)

Set objGroup = GetObject("LDAP://cn=_DisableUSBDrive, ou=Groups, dc=domain,
dc=com")

For Each strComputer in objGroup.Member
Set objMember = GetObject("LDAP://"; & strComputer)
readout.writeline objMember.CN
Next

readout.close

.



Relevant Pages

  • Re: Listing Users that are Part of the Local Administrator Group
    ... > I'm trying to find/write a script that can return the members of the Local ... > Administrator group on Win 2K/XP machines. ... > computers' local Administrator group. ... I've used a script similar to below to document the local Administrators ...
    (microsoft.public.scripting.vbscript)
  • Re: Startup Script Via GPO... Where Are Parameters Stored?
    ... If I am setting up a startup script in a gpo, ... the local administrator passwords yourself remotely. ... Any computers that could not be ... by default members of "Domain Admins" are members. ...
    (microsoft.public.scripting.vbscript)
  • Re: List Members of a Group (with user input)
    ... Wscript.Echo "No members" ... Dim objRootDSE, objTrans, strNetBIOSDomain, strGroup ... I would like one that does not require editing of the script each time. ... Dim UserCount, gga, CNgga ...
    (microsoft.public.scripting.vbscript)
  • Re: Add another domain user group to local administrators of all computers in an OU with removing ot
    ... If you have a group "mylocaladmins", which is added to restricted groups, with user1, user2 and user3 you can add or remove accounts to this group without effecting the other users in the group, they will still be local admins. ... But if you have so different needs with separating computers, you have to do a good planning before, what you will achive in for which users/groups. ... Select add on the Members of this group and then add the members ...
    (microsoft.public.windows.server.active_directory)
  • Re: How to create file on network share from ASP.NET
    ... but my point is exactly that both computers ARE ... NOT members of the same domain - one is standalone Win2003 and another is ... Administrators of Unix and Windows domain created for me ... >> asp with password asp which can access shared folder. ...
    (microsoft.public.dotnet.framework.aspnet)