We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Conditional Format with Data Bars Show Values in HTML Export - Regressive

Hello,

A worksheet with the “Data Bars” Conditional Format and the “Show Bar Only” option enabled - will show the underlying data values when exported to HTML. This is regressive - since it works as expected under Aspose Cells version 19.12 where the data values are hidden when exported to HTML.

This behavior can be seen in the latest Aspose Cells for Java version 21.3, the attached DataBarsCondFormat.xlsx file and the following Java code:

final String xlFile = [PATH] + "DataBarsCondFormat.xlsx";

Workbook wb = new Workbook(xlFile);

String htmlFile = xlFile.replace(".xlsx", "-v" + CellsHelper.getVersion() + ".html");
Files.deleteIfExists(Paths.get(htmlFile));
wb.save(htmlFile);
System.out.println("Successfully created HTML file:  " + htmlFile);

Running the above code should produce the attached DataBarsCondFormat-v21.3.0.html file. If you render the HTML output file in a Browser, you should see the data values from range B5:B15 superimposed over the colored Data Bars.

If you run the same code but using Aspose Cells for Java version 19.3, the code should produce the attached DataBarsCondFormat-v19.12.0.html file. If you render the HTML output file in a Browser, you should see the data values from range B5:B15 are hidden as shown in Excel and expected.

Environment Details:

  • Aspose Cells for Java 21.3
  • Java version 1.8.0_211
  • Windows 10 OS (but also reproducible under Linux).

File description in the DataBarsCondFormat.zip (30.7 KB) attachment contains:

  • DataBarsCondFormat.xlsx: Excel workbook to be used by the code above.
  • DataBarsCondFormat.png: Screenshot of the Conditional Format Rule applied to the Range B5:B15.
  • DataBarsCondFormat-v21.3.0.html: HTML output file produced from the code above under Aspose Cells 21.3.
  • DataBarsCondFormat-v19.12.0.html: HTML output file produced from the code above under Aspose Cells 19.12.

Thank you!

@oraspose,
We have observed the issue and logged it in our database for further investigation. You will be notified here once any update is ready for sharing.

This issue is logged as:
CELLSJAVA-43427 - Conditional Format with Data Bars Show Values in HTML Export

@oraspose,
This is to inform you that we have fixed your issue now. We will soon provide you the fixed version after performing QA and incorporating other enhancements and fixes.

@oraspose,
Please try our latest version/fix: Aspose.Cells for Java v21.3.6 (attached)
aspose-cells-21.3.6-java.zip (7.2 MB)

Your issue should be fixed now.

Let us know your feedback.

The fix looks very good.
Thank you!

@oraspose,
You are welcome.

The issues you have found earlier (filed as CELLSJAVA-43427) have been fixed in this update. This message was posted using Bugs notification tool by johnson.shi