Set-ADUser username -Remove
@{ProxyAddresses="smtp:username@domain.com"}
I ran this from "Active Directory Powershell for Windows PowerShell"
Because I'm not good enough with PowerShell yet, here's what I did. I tried to remove the domain from the account in Office365. Office365 returned all the mailboxes that had the domain as aliases. I copied and pasted the list of mailboxes to Excel. I extracted the mailbox user names from the list and made a single column in Excel of those mailbox names (in my case - our domain uses a username of joe.smith as the username for Joe Smith) so the single column included Joe.Smith. Then I did a mail merge with that list to create a get that PowerShell command listed above to be individualized with each username. And then I copied and pasted those commands into PowerShell. Not ideal. Ideally, you'd have a foreach command that would run though all AD users, but this is a story about what I did at this moment. I'll update this post.
1 comment:
I bookmarked pirateproxy to my bookmark site list and are checking back soon.
Post a Comment