如何使用C#将联系人添加到O365分配列表中?

发布于 2025-01-22 20:10:26 字数 138 浏览 3 评论 0原文

如何使用C#添加/从O365发行列表中添加/删除联系人?

在PowerShell中,可以使用命令add-DistributionGroupmember,从模块ExchangePowershell中删除DistributionGroupmember。

How can I add/remove contacts to/from O365 distribution lists using C#?

In PowerShell this can be done using the commands Add-DistributionGroupMember, Remove-DistributionGroupMember from the module ExchangePowershell.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

久光 2025-01-29 20:10:26

尚不清楚您想使用哪种技术。有几种方法可以

  1. 从C#应用程序中自动化Outlook中的C#完成工作。请参阅 :在Outlook中创建一个新的分发列表项目以获取更多信息。请注意,微软目前不建议,也不支持任何无人看管,非交互式客户端应用程序或组件(包括ASP,ASP,ASP.NET,DCOM和NT服务)的Microsoft Office应用程序的自动化,因为办公室可能会表现出不稳定的行为和/或僵局在此环境中运行时。在服务器端自动化的注意事项文章。

  2. 使用ews,请参阅在Exchange中探索EWS托管的API,EWS和Web服务有关更多信息。

  3. 使用Graph API,请参阅与Microsoft Graph中的组一起工作

It is not clear what technology you would like to use. There are several ways to get the job done in C#:

  1. Automate Outlook from your C# application. See How To: Create a new distribution list item in Outlook for more information. Note, Microsoft does not currently recommend, and does not support, Automation of Microsoft Office applications from any unattended, non-interactive client application or component (including ASP, ASP.NET, DCOM, and NT Services), because Office may exhibit unstable behavior and/or deadlock when Office is run in this environment. Read more about that in the Considerations for server-side Automation of Office article.

  2. Use EWS, see Explore the EWS Managed API, EWS, and web services in Exchange for more information.

  3. Use Graph API, see Working with groups in Microsoft Graph.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文