如何在 Azure 托管的 Web 应用程序服务中安装 Microsoft Reportviewer exe?

How to install Microsoft Reportviewer exe in web apps service hosted in azure?

在我的应用程序中,我们引用了以下两个 dll:

  1. Microsoft.ReportViewer.Common.dll
  2. Microsoft.ReportViewer.WebForms.dll

使用 ReportViewer 2010 版

但是在部署到 Azure Web 应用程序之后,我发现 .rdlc 文件在本地开发环境中工作时无效。在本地环境中,我已经安装了 reportviewer 安装程序。

以下是例外情况:

处理本地报表时出错。 报告的定义'Reports\Report1.rdlc'无效。

是否可以访问系统驱动器并在 Web 应用程序中安装 reportviewer.exe?

或者请给我一个生成rdlc文件的方法

这是解决方案:

  1. 在项目参考中添加 Microsoft.ReportViewer.ProcessingObjectModel.dll 以及 Microsoft.ReportViewer.Common.dll 和 Microsoft.ReportViewer.WebForms.dll
  2. 确保 Microsoft.ReportViewer.ProcessingObjectModel.dll、Microsoft.ReportViewer.Common.dll 和 Microsoft.ReportViewer.WebForms.dll 存在于已部署环境的 bin 文件夹中。

注意:确保所有dll的版本相同。