Forum Discussion
create dynamic distribution group in exchange online office 365
Exchange doesn't deal with "users", but with "recipients" - an object with an email address. Thus you cannot cover all users, only those with mailboxes or created as mail-enabled users. In addition, Exchange doesn't expose the employeeID attribute, so you cannot filter on that.
- Orion-SkolJul 16, 2020Brass Contributor
how are about excluding account contains specific word like Guest = mailto:GuestMS@CONTOSO
exclude any reciepient contains words guest?
- VasilMichevJul 16, 2020MVP
Guests are actually valid recipients, you can exclude them via the recipienttype. Excluding based on (part of the) name/alias is also possible. This article lists (most of) the properties you can use for creating a filter for Dynamic DG: https://docs.microsoft.com/en-us/powershell/exchange/recipientfilter-properties?redirectedfrom=MSDN&view=exchange-ps