cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

System.NullReferenceException: Object reference not set to an instance of an object.

Former Member
0 Likes
2,460

When our faxing application tries to convert the .rpt file (the document to be faxed) to PDF it invokesExportToDisk() method of CrystalReports dll and the call stack goes on till ExportToStream() method within the dll and then the error is thrown. Please see the error message displayed in event log below.

System.NullReferenceException: Object reference not set to an instance of an object.

at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)

at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext)

at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToDisk(ExportFormatType formatType, String fileName)

at NextGen.Faxing.FaxInterface.CryServStatic.ConvertToPDF(String strSrc, String strDest, Int32& numberOfPages)

at NextGen.Faxing.FaxInterface.MachineUtils.PrepareFaxDoc4MSFax(ServerType providerType, SentItem item, Int32& totalNumberOfPages)

at NextGen.Faxing.SvcProvider.MSFax.MSFaxProvider.Send(SentItem item, ItemStatus& status)

at NextGen.Faxing.FaxEngine.FaxEngine.SubmitFax(SentItem item, ItemStatus& status)

at NextGen.Faxing.FaxEngine.FaxProvider.SubmitFax(SentItem item, ItemStatus& status)

This only occurs when using version 13.0.24.xxxx. We don't experience the error if we continue to use version 13.0.14.xxx.

View Entire Topic
0 Likes

It means the report is no longer in focus, the ReportObject is null.

Windows or WEB app?

If a WEB app use Sessions and PostBack to keep the report in scope.

And verify the report exists, you may be trying to load a report that doesn't exist.