Click here to Skip to main content
15,993,805 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
hi all,
iam trying to pass the parameters to reportviewer vs 2010 using local mode to generate the reports.i tryed with this code,but
C#
protected void Button1_Click(object sender, EventArgs e)
{
ReportViewer1.ProcessingMode = ProcessingMode.Local;
ReportViewer1.LocalReport.ReportPath = "report.rdlc";
ReportParameter[] reportParameterCollection = new ReportParameter[2];
reportParameterCollection[0] = new ReportParameter();
reportParameterCollection[0].Name = "course_code";
reportParameterCollection[0].Values.Add("C1,C2,C3");
reportParameterCollection[0].Visible = false;

reportParameterCollection[1] = new ReportParameter();
reportParameterCollection[1].Name = "course_code";
reportParameterCollection[1].Values.Add("C1,C2,C3");
reportParameterCollection[1].Visible = false;

ReportViewer1.LocalReport.SetParameters(reportParameterCollection);

ReportViewer1.LocalReport.Refresh();
 }

i didn't get any output.could you tell me how to pass parameter
Posted
Updated 13-Oct-11 19:58pm
v3

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



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900