Hi all,
Wondering if anyone could help me with the following:
Would like to get all mailboxes that does not have *@domain.com as e-mail (default or alias) and export it to csv file.
Get-Mailbox -ResultSize Unlimited | Where-Object {($_.SMTPAddress -notcontains "*@domain.com*")} |export-csv C:\Scripts\mailboxes.csv
Tried the above but did not work.
Thanks!
Please mark as helpful if you find my contribution useful or as an answer if it does answer your question. That will encourage me - and others - to take time out to help you. Thank you! Off2work