Created
May 12, 2020 17:18
-
-
Save gjyoung1974/7ef2db7aa6448b386e0bd581fead2124 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get enabled members of a given AD group | |
get-adgroupmember "some-group" | | |
where {$_.objectclass -eq 'user'} | | |
Get-ADUSer -properties Name,Mail | | |
Select Name,Mail, Enabled | Where-Object {$_.Enabled -like “True”} | export-csv -path "C:\users\gordon.young\Desktop\some-group-05122020.csv" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment