Extract "pwdLastSet, Password expires, Password changeable, Password required, PowerShell

Copper Contributor

Extract "Password Last set, Password expires, Password changeable, Password required, User may change password" property for all Staff OU users and export to csv

1 Reply

Hello @Billvel,

Did you look into Get-ADUser and Export-Csv?

Get-ADUser -Filter * -SearchBase "OU=Staff,OU=UserAccounts,DC=FABRIKAM,DC=COM"- Properties * | Export-Csv -NoTypeInformation -Path Users report.csv

Hope that helps.