ASP.Net中的MS ReportViewer,如何传递参数值 [英] MS ReportViewer in ASP.Net, how to pass parameter values

查看:103
本文介绍了ASP.Net中的MS ReportViewer,如何传递参数值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


在我的ASP.Net项目中,我添加了一个数据报告并与数据集连接.它工作正常,但是我有两个问题:

1)我要在按下载有MSReportViwer的页面上的按钮后加载报告,说
这是显示报告"按钮.
目前,报表正以表单加载的方式加载.

2)我想将一些参数值传递给生成报告的sql查询.
例如,其中Name = @ NM和City = @ CT
NM和CT的值应在同一表格的文本框中给出.之后,我按下按钮显示报告",它应该显示报告.

请告知操作方法.
谢谢

解决方案

选中此

将报表与ASP.NET 3.5集成并从ASP.NET Web应用程序向报表发送参数 [ ^ ]


Hi,
In my ASP.Net project, I have added a data report and connected with dataset. It works fine but I have two issues:

1) I want to load the report after a button on the page carrying MSReportViwer is pressed, say
it is Show Report button.
At the moment report is loading just at form load.

2) I want to pass some parameter values to the sql query generating the report.
For example Where Name=@NM and City=@CT
values of NM and CT shall be given in the text boxes on the same form. After this i press the button ''Show Report'' and it should display the report.

Please advise how to do it.
Thanks

解决方案

Check this

Integrate Report with ASP.NET 3.5 and Send parameters to Report from ASP.NET Web Application[^]


这篇关于ASP.Net中的MS ReportViewer,如何传递参数值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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