最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

powershell - How do I filter Exchange Dynamic Distribution Groups for multiple potential criteria? - Stack Overflow

programmeradmin5浏览0评论

Here's the problem. One of the fields we are using to build our dynamic distribution list has the potential to have multiple values. It's an extension attribute that can have either a single value, like "123", or multiple values, like "765,123,626". I'm trying to get my dynamic distribution list filter to be able to pick up any user with "123". I know how to do this with regex in PowerShell using the -match or -contains operators. However, the filters for dynamic distribution lists are more restrictive. I have tried to use:

((CustomAttribute2 -like '$variableName*') -or (CustomAttribute2 -like '*$variableName'))

However, I get error messages basically saying that I can't use that filter. I've also tried:

(CustomAttribute2 -like '*$variableName*')

This produced an error message that wildcards cannot be used at the start of the expression.

I'm sure there's a way to do what I need to do, but I'm at a loss. Thank you for your time and thank you in advance for the help.

与本文相关的文章

发布评论

评论列表(0)

  1. 暂无评论