PowerShell get proxy addresses of users created in the last 30 days

$ProxyUsers = Get-ADUser -Filter * -Properties GivenName, Surname, ProxyAddresses, Created, UserPrincipalName | select GivenName, Surname, ProxyAddresses, Created, UserPrincipalName | where Created -gt (Get-Date).AddDays(-30) | where UserPrincipalName -Like “*.com”

For all I know, the where clauses can be combined and put into the Get-ADUser filter, but I couldn’t be bothered.

Advertisements

Comments are closed.

Blog at WordPress.com.

Up ↑

%d bloggers like this: