使用 MVC3 在报表查看器中回发
我正在使用带有 MVC3 的报表查看器控件。当我创建一个报告(例如 Report2.rdlc)并且有 150 条记录时,报告查看器的分页已完成。当我单击第 2 页按钮时,会调用回发函数,这会引发错误,因为我使用的是 MVC3。有什么解决方法可以实现第2页中的记录显示出来吗?
或者是否可以在一页中显示所有记录?我试过 1) 增加报表查看器和报表的高度。 2) 将 ShowPageNavigation 设置为 false。
请帮忙。
先感谢您。
I am using Report Viewer control with the MVC3. When I create a report say Report2.rdlc , and there are 150 records , the pagination of the Report viewer is done. When I click on the page 2 button, a postback function is called , which throws an error as i am using MVC3. Is there any workaround to achieve the records in the page 2 to be displayed.
Or is it possible to display all the records in one page itself? I tried
1) Increasing the height of the Report VIewer and the Report.
2) Setting the ShowPageNavigation to false.
Please Help.
Thankyou in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您在 MVC 视图中拥有 ReportViewer 控件吗?我只看到了使用 hacks/workarounds 进行的基本实现,通常高级功能会被破坏,因为 ReportViewer 依赖于 WebForms 中的东西,而这些东西在 MVC 中不可用。
您最好的方法是使用 iframe 和 WebForm 页面来获取完整功能,或者您是否尝试过打开/关闭异步渲染?
You have the ReportViewer control inside an MVC view? I have only seen a basic implementation work with hacks/workarounds, often advanced functionality is broken as ReportViewer relies on things from WebForms that aren't available in MVC.
You best approach would be to use an iframe and a WebForm page to get the full functionality or have you tried turning on/off async rendering?