Skip to Content
0

Invalid file name

Feb 20, 2017 at 01:30 PM

30

avatar image

Server Error in '/' Application.

Invalid file name.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Runtime.InteropServices.COMException: Invalid file name.

Source Error:

Line 15:     {
Line 16:         ReportDocument crystalReport = new ReportDocument();
Line 17:         crystalReport.Load(Server.MapPath("~/CustomerReport.rpt"));
Line 18:         Customers dsCustomers = GetData("select * from customers");
Line 19:         crystalReport.SetDataSource(dsCustomers);

Source File: c:\inetpub\vhosts\ thamaraat.com\ test.thamaraat.com\CS.aspx.cs Line: 17

Stack Trace:

[COMException (0x800001fb): Invalid file name.]
   CrystalDecisions.ReportAppServer.ClientDoc.ReportClientDocumentClass.Open(Object& DocumentPath, Int32 Options) +0
   CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.Open(Object& DocumentPath, Int32 Options) +90
   CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() +258

[CrystalReportsException: Load report failed.]
   CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() +321
   CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob) +851
   CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename) +78
   CS.Page_Load(Object sender, EventArgs e) in c:\inetpub\vhosts\thamaraat.com\test.thamaraat.com\CS.aspx.cs:17
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +51
   System.Web.UI.Control.OnLoad(EventArgs e) +92
   System.Web.UI.Control.LoadRecursive() +54
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.36373
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Don Williams
Feb 20, 2017 at 07:11 PM
0

What CR SDK are you using?

Try searching, lots of posts on how to connect to DataSets.

Share
10 |10000 characters needed characters left characters exceeded