List disabled mailboxes and export to CSV

[powershell]Get-Mailbox | where { $_.ExchangeUserAccountControl -eq “Accountdisabled” -and $_.recipienttypedetails -eq “usermailbox”  } | select name | Export-Csv c:disableduserswithmailboxes.csv[/powershell]

Leave a Reply

Your email address will not be published. Required fields are marked *

− 2 = 6