【问题标题】:Adding Outlook Interop To Visual Studio Project将 Outlook 互操作添加到 Visual Studio 项目
【发布时间】:2017-11-27 11:24:11
【问题描述】:

我正在使用 Visual Studio Community 2015,目前正在尝试将 Outlook 互操作添加到项目中。

目前我已经添加了两个 COM 引用:

  • Microsoft Office 15.0 对象库。
  • Microsoft Office 16.0 对象库。

很遗憾,我在程序集中找不到对 Microsoft.Office.Interop.Outlook 的引用,并且在使用时:

using Outlook = Microsoft.Office.Interop.Outlook;

我收到错误消息:

The type or namespace name 'Interop' does not exist in the namespace 'Microsoft.Office' (are you missing an assembly reference?)

根据我在网上阅读的内容,我应该能够看到所有的 Interop 程序集作为可添加的引用,是否正确?

【问题讨论】:

    标签: c# visual-studio-2015 outlook


    【解决方案1】:

    是的,你应该可以。

    在解决方案资源管理器中右键单击“引用”>“添加引用”> 选择左侧的 COM >(按名称排序)* > Microsoft.Office.Interop.Outlook > 确定

    *对我来说,列表从来都不是按顺序排列的,所以我总是要对列表进行排序,可能你也是这样

    这对我有用,这里还有其他建议:Cannot find Microsoft.Office.Interop Visual Studio

    【讨论】:

      猜你喜欢
      • 2012-12-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-03-18
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多