Need to apply styling to range of header cells with duplicate values


I am using a licensed version of Aspose cells(Java). I have a scenario involving styling application to a range of header cells containing duplicate values. The formatting works but the duplicate cell values are being modified by the API (some sequential numbers are being prepended to make these values unique).

Does the latest version of the API support duplicate values without modification of the original values? If possible, how can this be achieved?
Kindly help me. Thanks!


Please share your sample file and code snippet with us for our testing. We will reproduce the problem and provide our feedback after analysis. Please also try same steps with MS Excel and share your observations.

Thanks @ahsaniqbalsidiqui

Below are the relevant test code and snapshots:

//Test data before and after snapshots
Before styling.png (658.4 KB)
After Styling.png (687.7 KB)

//Code (1.4 KB)

As can be noticed from ‘After Styling.png’, cell value ‘G1’, ‘H1’ and ‘I1’ has been modified after styling. If this further helps, after applying styling, when trying to open the file again, seeing the following exception from recovery logs ‘Repaired Records: Table from /xl/tables/table1.xml part (Table)


I have observed both the issues i.e. modified values after styling and exception while opening this file in Excel. However you may save the file before styling and open it in Excel. Now apply the required table style to header row using Excel and observe values in Cells G1, H1 and I1. You will notice that Excel also modifies values in these cells. Please try it at your end provide the feedback.

Regarding the exception raised by Excel, we were able to observe the issue but we need to look into it more. We have logged the issue in our database for investigation and for a fix. Once, we will have some news for you, we will update you in this topic.

This issue has been logged as

CELLSJAVA-42831 - Exception raised by Excel after applying styling to range of header cells


We have investigated your issue a bit, it is caused by the duplicated columns’ name of table.
We will be fixing this issue. But its better that you have to change your code to avoid same columns’ name. We will share the fix with you once it is resolved.

Appreciate the quick turnaround on the issue @ahsaniqbalsidiqui

But its better that you have to change your code to avoid same columns’ name

Yes, that solution works but my problem here strictly requires to keep the duplicate column names unchanged.
It would be helpful if you could share the expected ETA on the related fix? Thanks!


The regular version containing this fix is planned to be released in the third week of March. You will be notified here when this version will be released.


Please try our latest version/fix: Aspose.Cells for Java v19.2.3: (6.4 MB)

Your issue should be fixed in it.

Let us know your feedback.

The issues you have found earlier (filed as CELLSJAVA-42831) have been fixed in Aspose.Cells for Java 19.3. This message was posted using BugNotificationTool from Downloads module by Amjad_Sahi