无法使用 InfoPath 2013 显示带有 .net 代码的表单,获取 "Error in the application"

Can not display form with .net code using InfoPath 2013, getting "Error in the application"

我们有 java 应用程序,它嵌入了 InfoPath ActiveX 控件来显示表单。使用 InfoPath 2010 一切正常。

当我使用 IP2013 时,我只能打开不包含 .NET 代码的表单。当我尝试打开包含 .NET 代码的表单时出现以下错误

(InfoPath:0x80043004) InfoPath cannot open the following file: path\to\file.
The form cannot be opened. To fix this problem, contact the form designer.
??
Form template: file:///path\to\template.xsn
InfoPath cannot open the selected form because of an error in the form's code.
Error in the application.

错误的具体含义是什么?我找不到错误代码或消息的解释。我该怎么做才能解决这个问题?

我的一些背景和测试运行:我有3个表格

  1. 使用 .NET 3.5 在 IP2007 中创建的表单
  2. 使用 .NET 3.5 在 IP2010 中创建的表单
  3. 使用 .NET 4.5 在 IP2013 中创建的表单
  4. 在任何版本的 InfoPath 中创建的表单,无需 .NET 代码

当我直接在 InfoPath 中打开表单时一切正常。当我使用 InfoPath ActiveX 在 java 应用程序中打开表单时,我得到以下信息

这原来是 Microsoft 的错误,特别是在 CLRLOADER.DLL 中。安装最新的服务包和补丁(KB3039714 对我有帮助)解决了这个问题