Click here to Skip to main content
13,288,520 members (61,646 online)
Rate this:
Please Sign up or sign in to vote.
See more:
I am trying to build a winform so that I can pass to it the parameters of any ssrs reports.
At present, I have one form which accepts two parameters to generate one specific ssrs report.
Can there be one form so that I can pass to it the parameters of any ssrs reports so that it generates the report.
This way, I do not have to have one winform for each ssrs report.
Any suggestions please?
this.reportViewer1.ServerReport.ReportServerUrl = new Uri(@"http://" + strMachineName + "/ReportServer");
this.reportViewer1.ServerReport.ReportPath = _strReportFolder + ReportName;
Microsoft.Reporting.WinForms.ReportParameter[] RptParameter = new Microsoft.Reporting.WinForms.ReportParameter[2];
RptParameter[0] = new Microsoft.Reporting.WinForms.ReportParameter("Parameter0", parameterValue0);
RptParameter[1] = new Microsoft.Reporting.WinForms.ReportParameter("Parameter1", parameterValue1);
Posted 14-Dec-12 4:40am
Updated 14-Dec-12 5:19am
arkiboys 14-Dec-12 10:51am
Hi, I do not see what you have posted.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

like the parameter , you can change the report name at run time to load different report in the same report viewer.

what you set here matters
this.reportViewer1.ServerReport.ReportPath = _strReportFolder + ReportName;

dont forget to call
every time you change the report name and report parameter.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web04 | 2.8.171207.1 | Last Updated 14 Dec 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100