【发布时间】:2009-09-19 00:14:49
【问题描述】:
我想发布我的 Web 应用程序并使用 Microsoft ReportViewer 查看报告。一切都在本地运行,但发布时我遇到了很多令人不安的错误。最后,我似乎遇到了一个我无法修复的问题。
到目前为止,我已经解决了前 3 个问题...
- 安装微软报告
查看器可再发行版 2008
包在我的服务器上。 - 将我的“rdlc”文件更改为“Content”并删除了 rdlc web.config 中的 buildProvider 文件。
- 在 IIS 中为 ReportViewer 配置托管处理程序
最后,ReportViewer 至少是可见的,并且它“似乎”正在尝试加载报告。但是现在我收到以下错误:
[InvalidCastException:无法投射 类型的对象 'Microsoft.Reporting.WebForms.ReportHierarchy' 输入 'Microsoft.Reporting.WebForms.ReportHierarchy'。] Microsoft.Reporting.WebForms.ReportDataOperation..ctor() +253 Microsoft.Reporting.WebForms.HttpHandler.GetHandler() +669 Microsoft.Reporting.WebForms.HttpHandler.ProcessRequest(HttpContext 上下文)+13
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +181 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean & completedSynchronously) +75
哦,太好了!当然,您不能将对象转换为它已经是的类型!!!!有人知道如何解决这个问题吗?
谢谢,
贾斯汀
【问题讨论】:
标签: reporting-services reporting reportviewer