发布网站而不安装Microsoft Report Viewer [英] Publishing Web site without installing Microsoft Report Viewer

查看:649
本文介绍了发布网站而不安装Microsoft Report Viewer的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个只有ftp访问权限的Web服务器,我无法在其上安装Microsoft Report Viewer。

I have a web server with ftp access only, and I can't install Microsoft Report Viewer on it.

如何将我的asp.net应用程序发布到IIS 没有安装ReportViewer

How do I publish my asp.net app to the IIS without installing ReportViewer?

我已将以下dll复制到我的站点bin文件夹:

I have copied following dlls to my site bin folder:


  • Microsoft.ReportViewer.WebForms.dll

  • Microsoft.ReportViewer.Common.dll

现在我收到错误消息:


本地报告处理期间发生错误。

报告'Reports\QuotationViewReport.rdlc'的定义无效。

报告处理中发生意外错误。

无法加载文件或程序集'Microsoft。 ReportViewer.ProcessingObjectModel,Version = 10.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a'或其依赖项之一。系统找不到指定的文件。

An error occurred during local report processing.
The definition of the report 'Reports\QuotationViewReport.rdlc' is invalid.
An unexpected error occurred in Report Processing.
Could not load file or assembly 'Microsoft.ReportViewer.ProcessingObjectModel, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.

我甚至找不到名为的Microsoft.ReportViewer的dll。我本地计算机上的ProcessingObjectModel.dll

是否可以在不安装ReportViewer的情况下发布我的应用程序?

Is it possible to publish my application without installing ReportViewer ?

推荐答案

先决条件:在开发计算机上安装Microsoft ReportViewer程序集(如 webkite回答)。

Pre-requisite : having Microsoft ReportViewer assemblies installed on your development machine (as answered by webkite).

在Visual Studio中,从项目的添加引用操作中,选择浏览选项卡并浏览到GAC。
(C:\ Windows \assembly\GAC_MSIL)。

In Visual Studio, from the "Add reference" action of your project, choose browse tab and browse to the GAC. (C:\Windows\assembly\GAC_MSIL).

在那里,找到Microsoft.ReportViewer.ProcessingObjectModel程序集文件夹,选择适合您需要的版本子文件夹,并将程序集添加为本地参考。

There, find the Microsoft.ReportViewer.ProcessingObjectModel assembly folder, choose the version sub folder suitable for your needs, and add the assembly as a local reference.

然后在引用列表中找到程序集,并将其本地副本属性切换为true。

Then locate the assembly in your references list, and switch its "local copy" property to true.

对于其他报表查看器程序集,您应该能够直接从添加引用对话框中的.Net选项卡添加它们。不要忘记将本地副本属性也切换为true。

For other report viewer assemblies, you should be able to add them directly from the .Net tab in "add reference" dialog box. Do not forget to switch the "local copy" property to true for them too.

使用此设置,reportviewer程序集将在每次构建时复制到构建目录,并且您应该能够轻松地将它们复制到目标部署环境。

With this setup, the reportviewer assemblies will be copied to your build directory at each build, and you should be able to copy them easily to your target deployment environment.

这篇关于发布网站而不安装Microsoft Report Viewer的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆