Je suis nouveau to powershell, mais J'ai been reading manuals et practiced a little bit.
My objective is to List tous users in tous Security Groups under specified path.
J'ai found le way to do it:
```
get-adgroup -Filter * -SearchBase "OU=Groups,DC=corp,DC=ourcompany,DC=Com" | %{Get-ADGroupMember $_.name} | ft name
```
But le problem is I do pas see le group name. All I get is a bunch of users.
It would be nice si someone could tell me how to display le group name avant tous le members of this group get listed.
Thanks.
Lister tous les groupes et leurs membres avec PowerShell sur Win2008r2
Re: Lister tous les groupes et leurs membres avec PowerShell sur Win2008r2
`Gimme the codes!` powers, activate!
```
$Groups = Get-ADGroup -Properties * -Filter * -SearchBase "OU=Groups,DC=corp,DC=ourcompany,DC=Com"
Foreach($G In $Groups)
{
Write-Host $G.Name
Write-Host "
```
$Groups = Get-ADGroup -Properties * -Filter * -SearchBase "OU=Groups,DC=corp,DC=ourcompany,DC=Com"
Foreach($G In $Groups)
{
Write-Host $G.Name
Write-Host "