Last post Jul 28, 2014 05:39 AM by aspsak
Jul 14, 2014 08:30 AM|Karthik_CR|LINK
I'm facing the following error while loading my Report on Crystal Report Viewer. I have placed my report file (.rpt) under CR_Reports folder.
ERROR Exception in FillCrystalReportViewer() :Load report failed.stack : at CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened()
at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob)
at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename)
at CustomReports.FillCrystalReportViewer(DataSet ds)
I'm using the following code to read the report path.
reportPath = Server.MapPath("/CR_Reports/CustomReport.rpt");
Also i'm writing the report path in my log file. The report path gives me the right path where i have placed the Report file. Then i'm using the following code to load the report and assigning the DataSet to the report.
ReportDocument reportDocument = new ReportDocument();
CustomReportViewer.Visible = true;
Session["CrystalReportSource"] = reportDocument;
CustomReportViewer.ReportSource = reportDocument;
Please help me to figure out the issue.
Jul 17, 2014 05:18 AM|Hiteshv|LINK
Just check once link as below:
It may occur because of your temp files so delete all your temp files.
Jul 22, 2014 12:56 AM|Ajay2707|LINK
Its very common issue,
I just given a answer and well explained as my experience in below link.
Jul 28, 2014 05:39 AM|aspsak|LINK
Hi, you may try with this.
reportPath = Server.MapPath("~/CR_Reports/CustomReport.rpt");