Span elements and table bottom line not converted from html to xls

Aspose team,

We are evaluating several HTML to XLS converters, including yours, Aspose.Cells for .NET. In an effort to compare, tested conversion of an html page, HOWEVER, have some questions with regards to conversion results.

  1. Noticed several html elements were excluded upon conversion:

HTML page span elements image attached to this topic.

Start Quarter = 2014-01, End Quarter = 2014-01 , totalEmployees between ‘‘1’’ and ‘‘100’’

XLS results (no sign of span elements) attached to this topic.

  1. Noticed line highlighted in yellow is not showing on xls results:

HTML page:

 <TABLE id="Table2" style="HEIGHT: 79px" cellSpacing="1" cellP
    <TR>
<TD style="WIDTH: 228px" colSpan="3">
<P><span id="lblHeading" style="display:inline-block;font-weight:bold;height:38px;width:133px;">No results matched your criteria</span><span id="exitUIAcctLbl" style="display:inline-block;font-weight:bold;height:38px;">0000422405</span></P>
</TD>
<TD align="left" colSpan="6"><span id="Label2" style="display:inline-block;font-weight:bold;height:38px;width:167px;">Exit Company Name: </span>&nbsp;
<span id="exitCompanyNameLbl" style="display:inline-block;font-weight:bold;height:38px;width:217px;">GOOD SAMARITAN DENTAL CLINIC LLC </span></TD>
</TR>
<TR>
<TD align="left" colSpan="9">
<P><span id="lblAddress1">C/O SCOTT TAYLOR</span></P>
<P><span id="lblCity">GREENVILLE</span>,
<span id="lblState">SC</span>&nbsp;&nbsp;&nbsp;
<span id="lblZip">29605-</span></P>
</TD>
</TR>
</TABLE>

XLS results (no sign of bottom table border element) image attached to this topic.

Is there a way to resolve these issues, this is keeping our team from making a final decision on which tool to purchase?

Regards,
Images.docx (81.9 KB)

@witschey,

Thanks for the details.

Please find attached the test.html file (I created it manually based on your HTML).
test.zip (572 Bytes)

When I opened the file into MS Excel, there are no borders at all. See the screenshot attached.
sc_shot1.png (60.5 KB)

Now I use the following sample code with Aspose.Cells for .NET v24.1 using the HTML file to generate an XLSX file:
e.g.
Sample code:

HtmlLoadOptions options = new HtmlLoadOptions(LoadFormat.Html);
Workbook workbook = new Workbook("g:\\test2\\test.html", options);
workbook.Save("g:\\test2\\out1.xlsx");

Please find attached the output XLSX file for your reference.
out1.zip (6.3 KB)

I think Aspose.Cells works the same way as MS Excel does. Do you find any difference when parsing HTML into MS Excel manually or rendering to XLSX from MS Excel?

Hello Sahi,

Try converting attached files:

Input.html (despite having div elements, for some reason first table row is gone after conversion).
Input_1 - Copy.html (span text elements are gone after conversion)
Input_2 - Copy.html (first table bottom border is gone after conversion)

Use this
Input.7z (2.7 KB)

code sample and you will see what am referring to:

Aspose.Cells.HtmlLoadOptions opts = new Aspose.Cells.HtmlLoadOptions(LoadFormat.Html);
opts.AutoFitColsAndRows = true;
opts.ConvertNumericData = false;
opts.SupportDivTag = true;
var workbook = new Workbook(Source_Path,opts);
workbook.Save(Output_Directory + “Aspose.xls”);

Regards,

Bart

@witschey
By using a sample file and code for testing, we can reproduce the issues. Found three issues: missing span text elements, missing HR black line elements, and missing table borders.

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-55005:Span text elements are gone after saving html to excel
CELLSNET-55006:HR black line elements are gone after saving html to excel
CELLSNET-55007:First table bottom border is gone after saving file to excel

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.

Hello John,

Normally, how long does it take for your team to resolve issues?

@witschey
Since your issue was logged yesterday, please allow us some time to evaluate and analyze it in detail. If it is not complex, we should be able to fix it soon, and the fix may be included in our next release (Aspose.Cells v24.2 - planned for publication in the second week of next month). If the issue is complex, it may take a few more weeks or even a month to resolve.

Additionally, if you purchase paid support, we will prioritize your issue so that it can be resolved earlier.

@witschey ,

We are pleased to inform you that your issues have been resolved. The fix will be included in an upcoming release (Aspose.Cells v24.2) that we plan to release in the first half of February 2024. You will be notified when the next version is released.
Attached is the result after fix for your reference: output.zip (14.6 KB)

Thanks, looking forward to release date. Can you please share .NET code utilized to convert html to excel on these files?

@witschey,

Generally, we publish releases in the second week of the month. The release date for the next version is not final, as releases are published once they are ready. Also, we used more or less the same code that you used, but with the latest fix to generate the resulting files.

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