im having trouble using the PUSH method to generate a report .
this is my code.
Try
cr1.Visible = False
Dim myConnection As New SqlClient.SqlConnection
myConnection.ConnectionString = "Data Source=someplace;Initial Catalog=somedb;User Id=someid;Password=somepass;"
Dim MyCommand As New SqlClient.SqlCommand
MyCommand.Connection = myConnection
MyCommand.CommandText = "Select * from asset where assetid < 10"
MyCommand.CommandType = CommandType.Text
Dim MyDA As New SqlClient.SqlDataAdapter
MyDA.SelectCommand = MyCommand
Dim myDS As New dyn_dataset
'This is our DataSet created at Design Time
MyDA.Fill(myDS, "asset")
Dim oRpt As New dyn_report2
' This is the Crystal Report file created at Design Time
oRpt.SetDataSource(myDS)
cr1.ReportSource = oRpt
' Set the Crystal Report Viewer's property to the oRpt Report object
cr1.Visible = True
Catch e As Exception
Response.Write("<h3>" & e.Message & "</h3>")
Response.Write("<h3>" & e.Source & "</h3>")
Response.Write("<h3>" & e.StackTrace & "</h3>")
End Try
and this is my error message
////////////////
Load report failed.
CrystalDecisions.CrystalReports.Engine
at .F(String , EngineExceptionErrorID ) at .B(String , Int32 ) at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String reportName, OpenReportMethod openMethod, Int16 parentJob) at CrystalDecisions.CrystalReports.Engine.ReportClass.Load(String reportName, OpenReportMethod openMethod, Int16 parentJob) at CrystalDecisions.CrystalReports.Engine.ReportDocument.SetDataSource(Object value) at sam_test.dyn_test.BindReport() in c:\inetpub\wwwroot\sam_test\CHANGECONN\dyn_test.aspx.vb:line 51
///////////////////
i know the report is their but i keep getting a load report failed