powershell exchange 2007 character question

Posted on 2011-10-17
Last Modified: 2012-08-14
In our organization we use special characters in the display name to differentiate a shared mailbox, versus user mailboxes, versus distribution list.What I am trying to do is find user mailboxes which are incorrectly created with the wrong character.

Get-User -ResultSize Unlimited | Where {$_.RecipientType -eq "UserMailbox" -and $_.Displayname -contains '^' -and $_.Displayname -contains '|' -and $_.Displayname -contains '@'}

I was hoping to shorten this and trying to group the special characters together.
Question by:techdrive
    1 Comment
    LVL 16

    Accepted Solution

    Shortening as in speed?  Have you tried piping each result as in:

    Get-User -ResultSize Unlimited | Where {$_.RecipientType -eq "UserMailbox"} | Where ($_.Displayname -contains '^') | Where ($_.Displayname -contains '|') | Where ($_.Displayname -contains '@')}

    Featured Post

    Threat Intelligence Starter Resources

    Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

    Join & Write a Comment

    Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
    Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
    In this video we show how to create a Contact in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Contact ta…
    This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now