1812455 - Exporting a report with subreports to XLS file format results in unhandled C++ exception

SAP Knowledge Base Article - Public

1812455 - Exporting a report with subreports to XLS file format results in unhandled C++ exception

Symptom

  • Using a Visual Studio 2010 application
  • Exporting a report with subreports to an XLS file format results in an unhandled C++ error
  • Using ExportToDisk function
  • Application is forced to close

Environment

  • Crystal Reports for Visual Studio 2010
  • Visual Studio 2010

Reproducing the Issue

  • Use the following code to export a report to XLS:
    crDiskFileDestinationOptions.DiskFileName = ExportPath + "Excel.xls"
        'set the required report ExportOptions properties
         With crReportDocument.ExportOptions
             .ExportDestinationType = ExportDestinationType.DiskFile
             .ExportFormatType = ExportFormatType.Excel
             .DestinationOptions = crDiskFileDestinationOptions
         End With
    crReportDocument.Export()

 

Resolution

Download Service Pack 5 for SAP Crystal Reports, developer version for Microsoft Visual Studio

Keywords

CR2010 2010 CR4VS2010 CR4VS VS2010 NET2010 Crystal Reports for .NET Framework 4.0 crforvs 13 2012 , KBA , BI-DEV-NET-SDK , .NET SDK / COM SDK , Problem

Product

SAP Crystal Reports, developer version for Microsoft Visual Studio