Crystal reports in C#.net

  • Thread starter Thread starter radha
  • Start date Start date
R

radha

Hi

I am a beginner, trying to open a crystal report using crytal report
viewer in my webform. But nothing happens when I open the page. I am
not sure where I went wrong. This is my code in page load. Please
someone help me


CrystalReportViewer1 = new
CrystalDecisions.Web.CrystalReportViewer();
String reportPath = @"C:\Program Files\Crystal
Decisions\Crystal Reports 10\Samples\En\Reports\General Business\World
Sales Report.rpt";
StockObjectsReport = new ReportDocument();
StockObjectsReport.Load(reportPath);
CrystalReportViewer1.ReportSource = StockObjectsReport;

Thanks
 
After your ReportSource, you need the following:

CrystalReportViewer1.DataBind();
 
Back
Top