windows:powershell:get-adorganizationalunit
Table des matières
Get-ADOrganizationalUnit
Script
Voici le bout de script qui vous donnera la réponse
$TAB=@() Get-ADOrganizationalUnit -Filter * | %{ $OU = New-Object System.Object $OU | Add-Member -type NoteProperty -name OU -value $_.DistinguishedName $OU | Add-Member -type NoteProperty -name NBUser -value (@(Get-ADUser -Filter * -SearchBase $_.DistinguishedName -SearchScope 1 ).count) $TAB+=$OU } $TAB | Out-File -FilePath ADCount.txt
— sylvain 2020/02/20 15:45
windows/powershell/get-adorganizationalunit.txt · Dernière modification : de 127.0.0.1
