Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8653

Re: What is the cause of this Load report failed error?

$
0
0

I'm starting to think that there is something seriously messed up with the project. Three things to do:

 

 

1) Create a brand new project. You can use this code:

 

Private Sub CrystalReportViewer1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles CrystalReportViewer1.Load

        Dim crReportDocument As New CrystalDecisions.CrystalReports.Engine.ReportDocument

        crReportDocument.Load("C:\Users\kkleven\Documents\Visual Studio 2012\Projects\CigCrystalReports2013\CigCrystalReports2013\bin\Debug\BranchList_2013.rpt")

        CrystalReportViewer1.ReportSource = crReportDocument

    End Sub

 

or

 

 

 

Public Sub New()

 

        ' This call is required by the designer.

        InitializeComponent()

 

        ' Add any initialization after the InitializeComponent() call.

       'CrystalReportViewer1.ReportSource = "C:\Users\kkleven\Documents\Visual Studio 2012\Projects\CigCrystalReports2013\CigCrystalReports2013\bin\Debug\BranchList_2013.rpt"

    End Sub

 

2) If the new project also does not work, copy the report file to some test directory. I'd suggest c:\test. Then change the path in the above new app to load the report from c:\test. Does that work?

 

3) Use Process Monitor, see what is happening when the report engine attempts to load the report.

 

 

- Ludek


Viewing all articles
Browse latest Browse all 8653

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>