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

Free Support Forum - aspose.com

Aspose.Cells not converting HTML to Excel correctly

I have used Aspose.Cells in my project and The HTML table is not rendering into excel correctly. It is completely getting distorted. Kindly help in this matter.HTML code.zip (7.9 KB)

I have attached HTML file as well. Please look into this and kindly provide support. Thanks.

We reproduced the issue as you mentioned by rendering your HTML file to XLSX file format. We found tables are not rendered correctly.
e.g.
Sample code:

HtmlLoadOptions htmlLoadOptions = new HtmlLoadOptions(LoadFormat.Html);
htmlLoadOptions.AutoFitColsAndRows = true;

string html = File.ReadAllText("e:\\test2\\HTMLTAB.txt");
var workbook = new Workbook(new MemoryStream(Encoding.UTF8.GetBytes(html)), htmlLoadOptions);
workbook.Save("e:\\test2\\out1.xlsx");

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): CELLSNET-52630

You can obtain Paid Support services if you need support on a priority basis, along with the direct access to our Paid Support management team.

@sanjaykrishnats
We have fixed your mentioned issues. Please check dest.zip (13.0 KB)
generated by inner hotfix 23.1.4.

Thank You so much, It rendered just fine. Can you please let me know when this fix will be released ? in which version etc

@sanjaykrishnats,

The fix will be included in our upcoming release (Aspose.Cells v23.2) which is scheduled in the first half of February 2023. You will be notified once the next release is published.

1 Like