【问题标题】:How to use Application dialogs in c#?如何在 C# 中使用应用程序对话框?
【发布时间】:2020-05-22 20:59:25
【问题描述】:

我正在尝试按照这个 Microsoft 教程在 c# 中显示分发列表的名称

https://docs.microsoft.com/en-us/office/client-developer/outlook/pia/how-to-get-members-of-an-exchange-distribution-list

This example prompts the user to select an Exchange distribution list from the Select Names dialog box and expands the distribution list to display its members.

除非我在这里遇到错误

我在控制台应用程序项目中有这个。我该如何解决这个问题?

【问题讨论】:

    标签: c# dialog


    【解决方案1】:

    您可以按照屏幕截图中提示的建议,通过创建应用程序实例来解决此问题。像这样:

    Application app = new Application();
    Outlook.SelectNamesDialog snd = app.Session.GetSelectNamesDialog();
    

    来源:

    1. How to invoke a method with (Outlook.Application application) as parameter in C#?

    【讨论】:

      猜你喜欢
      • 2011-02-12
      • 1970-01-01
      • 2022-07-12
      • 1970-01-01
      • 1970-01-01
      • 2017-11-26
      • 1970-01-01
      • 2020-06-21
      • 1970-01-01
      相关资源
      最近更新 更多