Skip to Content
0
Former Member
Mar 23, 2009 at 09:50 PM

VS2008 Passing paramaters to crystal reports Does it work ? Help please

19 Views

Hi

I have been going mad trying to pass a parameter to a very simple report.

I have looked at loads of posts and I can't get any of them to work , is this because I am using VS2008.

I am unable to open the sample projects provided with crystal reports , it says they were created for a previous version of asp.net. When I convert it to ASP.NET 3.5 the web config file is invalid.

The simplest way I could find to pass a parameter was the following

customers = new ReportDocument();

string reportPath = Server.MapPath("Customers.rpt");

customers.Load(reportPath);

customers.SetParameterValue("Phone", "123");

CrystalReportViewer1.ReportSource = reportPath;

Can anyone give me a link to a simple project that passes a parameter and works.

Thanks