balabommala
asked on
Load report failed in Visual Studio .NET 2002
Hello everybody out there,
I used Visual Studio .NET 2002 to build reports. It is a pure reporting application with around 25 reports. The reports are embedded. Iam using the bundled version of Crystal Reports.
I have created a setup program with around 6 merge modules( 4 merge modules+2 more because I am using ADO.NET datasets). When that setup program is installed on my friend's system, it runs fine. The problem is when I try to run the reports on the development server, I get the error “Load Report Failed”.
How can I make the report run after installation on the "user's" PC? Please anybody help......
Please don't point me to any url's as I have done enough research. Don't point me to this link especially.
http://support.businessobjects.com/communityCS/TechnicalPapers/crnet_deployment.pdf
Thanks a mill.
I used Visual Studio .NET 2002 to build reports. It is a pure reporting application with around 25 reports. The reports are embedded. Iam using the bundled version of Crystal Reports.
I have created a setup program with around 6 merge modules( 4 merge modules+2 more because I am using ADO.NET datasets). When that setup program is installed on my friend's system, it runs fine. The problem is when I try to run the reports on the development server, I get the error “Load Report Failed”.
How can I make the report run after installation on the "user's" PC? Please anybody help......
Please don't point me to any url's as I have done enough research. Don't point me to this link especially.
http://support.businessobjects.com/communityCS/TechnicalPapers/crnet_deployment.pdf
Thanks a mill.
Is Crystal and VS installed on the development server?
mlmvv
mlmvv
ASKER
VS(I mean .NET Framework 1.0.3075 is installed) is installed on the development server. and Crystal comes with VS.NET right
ASKER
This is how I was calling the report:
Any suggestions please.
Private Sub CallReport()
'Dim stor_loc
'stor_loc = Request.QueryString("stora ge")
Dim objDS As DataSet
objDS = GetFilings()
' Creating the XML file for design and report
'objDS.WriteXmlSchema("C:\ ReportsAll EmployeeSt atistics.x ml")
' Assigning the Dataset to the report
oRpt.SetDataSource(objDS)
objDS = Nothing
'With CrystalReportViewer1
'.ReportSource = oRpt
'.BestFitPage = True
' End With
Dim crExportOptions As ExportOptions
crExportOptions = oRpt.ExportOptions
With crExportOptions
.FormatOptions = New PdfRtfWordFormatOptions()
.ExportFormatType = ExportFormatType.PortableD ocFormat
.ExportDestinationType = ExportDestinationType.Disk File
End With
Dim req As ExportRequestContext = New ExportRequestContext()
req.ExportInfo = crExportOptions
Dim st As System.IO.Stream
st = oRpt.FormatEngine.ExportTo Stream(req )
oRpt = Nothing
Response.ClearContent()
Response.ClearHeaders()
Response.ContentType = "application/pdf"
Dim b(st.Length) As Byte
st.Read(b, 0, st.Length)
Response.BinaryWrite(b)
st.Close()
st = Nothing
End Sub
Any suggestions please.
Private Sub CallReport()
'Dim stor_loc
'stor_loc = Request.QueryString("stora
Dim objDS As DataSet
objDS = GetFilings()
' Creating the XML file for design and report
'objDS.WriteXmlSchema("C:\
' Assigning the Dataset to the report
oRpt.SetDataSource(objDS)
objDS = Nothing
'With CrystalReportViewer1
'.ReportSource = oRpt
'.BestFitPage = True
' End With
Dim crExportOptions As ExportOptions
crExportOptions = oRpt.ExportOptions
With crExportOptions
.FormatOptions = New PdfRtfWordFormatOptions()
.ExportFormatType = ExportFormatType.PortableD
.ExportDestinationType = ExportDestinationType.Disk
End With
Dim req As ExportRequestContext = New ExportRequestContext()
req.ExportInfo = crExportOptions
Dim st As System.IO.Stream
st = oRpt.FormatEngine.ExportTo
oRpt = Nothing
Response.ClearContent()
Response.ClearHeaders()
Response.ContentType = "application/pdf"
Dim b(st.Length) As Byte
st.Read(b, 0, st.Length)
Response.BinaryWrite(b)
st.Close()
st = Nothing
End Sub
Your code is not complete, you should have a line like
oRpt = new CrystalReport1() don't you?
dylan
oRpt = new CrystalReport1() don't you?
dylan
ASKER
I have that in another function.
This whole application is working in my system. But when i tryto deploy it on he development server, it doesn't.
Do I have to include Dbghelp.dll into my setup project?
Thanks
This whole application is working in my system. But when i tryto deploy it on he development server, it doesn't.
Do I have to include Dbghelp.dll into my setup project?
Thanks
I don't think include DBghelp.dll will help. You could try it anyawy.
I still suspect that you didn't actally embedded your report with your project. From you report's property, did you change your Build Action to "Embedded Resource"?
dylan
I still suspect that you didn't actally embedded your report with your project. From you report's property, did you change your Build Action to "Embedded Resource"?
dylan
ASKER
By default, the reports Build Action property is set to Embedded resource right.
Anyways I checked my reports and all of them have enmedded resource as build action.
Thanks
Anyways I checked my reports and all of them have enmedded resource as build action.
Thanks
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER
Thanks.
You ponited me to the right link.
You ponited me to the right link.
glad I could help~
dylan
dylan
May I know how did you call up your report to display? mind to show us your code?
dylan