Error on Run Reports - DevExpress, UseNativeFormat


 Product(s):Promis.e
 Version(s):08.11.12.xx
 Environment:N\A
 Area:Reports_Output Features
 Subarea:Reporting

Error Message

When trying to run or preview certain templates using [[Run Reports]], the following error occurs and the report does not run:

Internal Error
Error Message: 1487: 'DevExpress.XtraPrinting.XlsExportOptions' does not
contain a definition for 'UseNativeFormat'
TargetSite: DevExpress.XtraReports.UI.XtraReport Compile(System.String,
System.IServiceProvider)
DeclaringType: DevExpress.XtraReports.Native.ReportCompiler
Attributes: internal static
MemberType: Method

An similar error also occurs when trying to open the template in [[Report Template Designer]].

Explanation

This error is caused by the presence of a deprecated ExportOptions.Xls.UseNativeFormat property in the template file.

How To Avoid

If the template was included in a previous version of the software, use the template supplied with your current version of the software. This may mean getting the .rpt file from the data folder installed by the new software or from the [[Default Data folder contents|PromiseDataArchive.zip]] file.

If the template is custom or current versions cannot be obtained, the problem can be fixed with the following method:

  1. Make a backup copy of the problem .rpt file.

  2. Open the .rpt file in Notepad.

  3. Select Edit > Replace.

  4. Find "this.ExportOptions.Xls.UseNativeFormat" and replace with "//this.ExportOptions.Xls.UseNativeFormat"

  5. Click the Replace button until it finds none.

  6. Save the .rpt file.

 Original Author:Matt_P

P/S 92315, 500000102527