Tuesday, February 21, 2012

ReportViewer1.SetQueryParameter getting message not a member of reportviewer

I am using the reportviewer control in vs2003 accessing the rs2005.

I get the message setqueryparameter is not a member and also i do

****************************************************************

PrivateSub populateReportViewer()

ReportViewer1.ServerUrl = "http://localhost/ReportServer"

ReportViewer1.ReportPath = "/SampleReports/Product Line Sales"

ReportViewer1.SetQueryParameter("ProductCategory", CategoryDropDown.SelectedValue)

ReportViewer1.SetQueryParameter("ProductSubCategory", SubCategoryDropDown.SelectedValue)

ReportViewer1.SetQueryParameter("StartDate", StartDate.Text)

ReportViewer1.SetQueryParameter("EndDate", EndDate.Text)

ReportViewer1.Parameters = Microsoft.Samples.ReportingServices.ReportViewer.multiState.False

ReportViewer1.Format = "HTML4.0"

EndSub

PublicSub SetQueryParameter(ByVal ParamName AsString, ByVal ParamValue AsString)

SetParameter(ParamName, ParamValue)

EndSub

***************************************************************************************

Please can someone provide me a sample code how to use the reportviewer control to call a report via storedproc with parameters.

Please help thank you very much for the information.

see this page : http://www.codeproject.com/aspnet/Reporting_Services.asp

Hope this will help

No comments:

Post a Comment