Hello all,
I need to remove some SMTP addresses for a domain that will be going away. My plan is to round up the users who are no longer receiving at the address, and put there usernames in a csv file. Then run the below at the end of the day. Am I going about this the right way?
$users = names.csv foreach($user in $users){ Set-ADUser -Identity $users -Remove {$_.proxyAddresses -eq "*@domain.com"} }
submitted by /u/grrrrshell
[link] [comments]
The post Remove SMTP from AD attribute appeared first on How to Code .NET.