Results 1 to 3 of 3

Thread: crystal report load failed error

Threaded View

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Jul 2007
    Posts
    617

    crystal report load failed error

    Hi, after head dropping research it seems none of the solution work for me regarding the above error. It works in development server but I'm having these hiccup in the production.

    I'm using:
    windows xp iis5
    msvs 2005
    crystal report 10
    sql server 2005

    Also I did :
    set x:\windows\temp folder to everyone with full access
    set CR registry printjob to -1
    restart IIS

    hardcoded CR path


    VB
    Code:
        Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
            Try
                Call BindReport()
            Catch ex As Exception
               do something here...
            End Try
    
        End Sub
    
    
    Sub BindReport()
    
            Using thisconnection As SqlConnection = New SqlConnection(ConfigurationManager.ConnectionStrings("ConnectionString").ConnectionString)
    
                Using cmd As SqlCommand = New SqlCommand(Server.HtmlEncode(Request.Cookies("drc_cookie")("rptform_filter")).ToString, thisconnection)
    
                    Dim MyDA As New SqlDataAdapter
                    MyDA.SelectCommand = cmd
    
                    Dim myDS As New de_logsDataSet
                    MyDA.Fill(myDS, "tbldelayevents")
    
                    oRpt.Load(Server.MapPath("~\reports\de_logsCrystalReport.rpt"))
                    oRpt.SetDataSource(myDS)
    
                    CrystalReportViewer1.ReportSource = oRpt
                End Using
    
            End Using
    End Sub
    
    
    
    
    
        Protected Sub Page_Unload(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Unload
            CrystalReportViewer1.Dispose()
            CrystalReportViewer1 = Nothing
            oRpt.Close()
            oRpt.Dispose()
    
            GC.Collect()
        End Sub
    help appreciated.
    Last edited by jlbantang; Apr 18th, 2011 at 08:37 AM.
    Learn something new every .001 second.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width