【问题标题】:Outlook 2010 Add-In not working with error Exception from HRESULT: 0x8004063EOutlook 2010 加载项无法处理来自 HRESULT 的错误异常:0x8004063E
【发布时间】:2016-05-25 18:46:28
【问题描述】:

我们有一个 Outlook 2010 插件,它在使用 .NET Framework 4.0 之前运行良好。 .NET 框架升级到 4.5.2 后,它停止在一些用户的机器上加载(不是每个人都出现这个问题,在我的机器上工作正常)。在阅读了几篇博客后,我将值 0 分配给用户机器中的环境变量 VSTO_SUPPRESSDISPLAYALERTS 并在打开 Outlook 并尝试加载我们的加载项时收到以下错误:

Exception from HRESULT: 0x8004063E

************** Exception Text **************
System.Runtime.InteropServices.COMException (0x8004063E): Exception from HRESULT: 0x8004063E
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode, IntPtr errorInfo)
at Microsoft.VisualStudio.Tools.Office.Runtime.DomainCreator.CreateCustomizationDomainInternal(String solutionLocation, String manifestName, String documentName, Boolean showUIDuringDeployment, IntPtr hostServiceProvider, Boolean useFastPath, IntPtr& executor)
at Microsoft.VisualStudio.Tools.Office.Runtime.DomainCreator.Microsoft.VisualStudio.Tools.Office.Runtime.Interop.IDomainCreator.CreateCustomizationDomain(String solutionLocation, String manifestName, String documentName, Boolean showUIDuringDeployment, IntPtr hostServiceProvider, IntPtr& executor)

使用 .Net Framework 4.0 对我们来说不是一个选项,我们必须使用 4.5.2。我也尝试删除注册表项 HKEY_CURRENT_USER\Software\Microsoft\VSTO\SolutionMetadata 并重新安装加载项,但没有奏效。 但是,我注意到的一件事是用户的机器在上述注册表项下没有 PreferredClr 值。它只包含一个名为 compatibleFrameworks 的值,其中包含数据:

<compatibleFrameworks xmlns=\"urn:schemas-microsoft-com:clickonce.v2\">

<framework targetVersion=\"4.5.2\" profile=\"Full\" supportedRuntime=\"4.0.30319\" />

</compatibleFrameworks>

任何帮助将不胜感激。谢谢!

P.S:所有机器都使用 Windows 7。

【问题讨论】:

    标签: c# windows-7 vsto outlook-addin .net-4.5.2


    【解决方案1】:

    重新安装 Microsoft Visual Studio 2010 Tools for Office Runtime (x64) 解决了该问题。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-02-17
      • 2021-05-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-03-01
      • 1970-01-01
      • 2021-05-05
      相关资源
      最近更新 更多