Does anybody know if you can copy members of a Active Directory folder into Excel
I have about 150 members of a Active Directory folder. Within Active Directory you find the group folder. Go to properties. Then the member tab. Then you see the members. I want to move those members into a spreadsheet without manually typing them in. Is there anyway to do this? Thanks.
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
Assuming you're talking about dumping the membership of an AD Group to a spreadsheet, the easiest way is to use PowerShell, and the following command:
get-adgroupmember "group name" | select-object logonname, firstname, lastname | export-csv c:\filename.csv
Caveats: the command pipes its output into a CSV file. You can select additional properties of the user accounts if you need them in your spreadsheet (e.g. sAMAccountName if you want the user's actual AD user account name). Search technet.microsoft.com for more examples on usage etc.
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
What do you mean by "Active Directory folder" ? Do you mean an OU?
Learn Powershell - it's awesome. With the Quest ActiveRoles cmdlets:
Get-QADGroupMember "group name here" -Indirect -SizeLimit 0 | Select SamAccountName,Email,DisplayName | Export-Csv -NoTypeInformation c:\blah.csv
Note that "indirect" also gets the members of nested groups. Remove that if you just want the members of that group, even if it includes other groups, but you might need to change the output selection to make it look sensible.
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
Thanks for the respones. But I was hoping for easier. Sorry, way over my head. I'll get busy typing.
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
Scratch that, I obviously didn't read your post...
If you have the option to install PowerGUI you can do it through this once you have the AD management powerpack installed. Select group>click "members" or "members (recursive)" as required, click export to CSV.
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
In AD Users and Computers just right click the OU and select the Export list and save as CSV.
Mark
p.s. Powershell is awesome, definatly learn it :)
Re: Does anybody know if you can copy members of a Active Directory folder into Excel
Quote:
Originally Posted by
mark19632
In AD Users and Computers just right click the OU and select the Export list and save as CSV.
Mark
Ahh must read the whole thread, you're talking about a group!
Defiantly use Powershell