Sorting with DataSorter affects table formatting

Dear Aspose team,

We would like to sort data the same way Excel does when you select the rows to sort then do right-click > sort:
image.png (15.1 KB)

As you can see, we’ve sorted on column A and the table formatting (the border marked with the red arrow) stays at the bottom of row 7.

However, when sorting with DataSorter in Aspose, the bottom border stays attached to Bank of Ireland, as if the whole row was cut and pasted into the new position:
image.png (13.9 KB)

I’ve searched through the documentation, but there isn’t seem to be an option to specify how you want to move the data around:

Can you please advise on how to achieve Excel’s sorting?
If a fix needs to be done, it might be worth it to allow users to specify if they want to sort only the text, text+text formatting, text+all formatting, etc with something similar to the enum PasteType.

I am attaching a zip folder with example code, input, expected output and Aspose output.

Sort affecting table (29.2 KB)



Please notice, I am able to reproduce the issue as you mentioned (via screenshots) by using your template file. I found when sorting with DataSorter, the bottom border stays attached to “Bank of Ireland” text, as if the whole row was cut and pasted into the new position which is opposite to MS Excel. MS Excel does not do this way when sorting data. I have logged a ticket with an id “CELLSNET-49758” for your issue. We will look into it soon.

Once we have an update on it, we will let you know here.


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.

Please try our latest fix.
Aspose.Cells21.11.5 For .Net2_AuthenticodeSigned.Zip (5.6 MB)
Aspose.Cells21.11.5 For .Net4.0.Zip (5.6 MB)
Aspose.Cells21.11.5 For .NetStandard20.Zip (5.6 MB)

The issues you have found earlier (filed as CELLSNET-49758) have been fixed in this update. This message was posted using Bugs notification tool by simon.zhao