Online Exchange Dynamic distribution group filter by Manager

Doboman 86 Reputation points
2021-10-26T04:14:36.193+00:00

Hi team ,

I need to create DDL and filter by Manager,as a test did the below.
I'm not getting any results & no errors.

$Filter = "((Manager -eq 'John Doh') -and (ExchangeUserAccountControl -ne 'AccountDisabled'))"
Get-Recipient -RecipientPreviewFilter $Filter | ft displayname, title

Also tried

(Manager -eq 'CN=first last,OU=testOU,OU=Office,DC=consto,DC=com')

So what I'm missing ?
Thank you Kindly.

Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,437 questions
0 comments No comments
{count} votes