Share via

Remove CustomAttribute14

Love Doktor 1 Reputation point
2021-07-19T10:23:56.137+00:00

Hi

We have the following distribution list set up on our Exchange server

Computing Staff
((((Department -like 'Computing') -or (CustomAttribute14 -like 'Computing'))) -and (-not(Name -like 'SystemMailbox{')) -and (-not(Name -like 'CAS_{')) -and (-not(RecipientTypeDetailsValue -eq 'MailboxPlan')) -and (-not(RecipientTypeDetailsValue -eq 'DiscoveryMailbox')) -and (-not(RecipientTypeDetailsValue -eq 'ArbitrationMailbox')))

I am new to Exchange Powershell.

I would like to remove CustomAttribute14 -like 'Computing')))

What is the correct command and syntax to do this?

Also where is a good place to find resources to learn powershell and exchange powershell?

Many thanks,

Anthony

Exchange | Exchange Server | Management
Exchange | Exchange Server | Management

The administration and maintenance of Microsoft Exchange Server to ensure secure, reliable, and efficient email and collaboration services across an organization.

{count} votes

1 answer

Sort by: Most helpful
  1. Anonymous
    2021-07-20T08:13:31.997+00:00

    Hi @Love Doktor ,

    It should be a Dynamic Distribution Group right?

    116233-image.png

    So if you want to remove the CustomAttribute14, you should use Set-DynamicDistributionGroup to rewrite the RecipientFilter:

    Set-DynamicDistributionGroup -Identity DDG -RecipientFilter "Department -like 'computing'"  
    

    116194-image.png

    For more information about the RecipientFilter parameter, you could find it on the above document(Set-DynamicDG).
    Note if you use Exchange Management Shell(EMS) to set the RecipientFilter or other parameter that the EAC doesn't have, the EAC will not be able to used to modify the Membership settings:
    After run:
    116213-image.png
    Before:
    116206-image.png

    And these document would be helpful: Custom filters using the RecipientFilter parameter and Filterable properties for the RecipientFilter parameter on Exchange cmdlets

    Best regards,
    Lou


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.