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

Free Support Forum - aspose.com

Some HTML files cause exception at attempt to create Workbook from them

Following simple HTML files without complex formatting or dynamic content cause strange exception at attempt to load them as Excel worksheet:
Samples.ZIP (1.2 KB)

Code sample:

var loadOptions = new HtmlLoadOptions(LoadFormat.Html);
var noteWb = new Workbook(htmlPathPath, loadOptions);

Exception message: “Item has already been added. Key in dictionary: ‘sub’ Key being added: ‘sub’”.
Stack:

at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)
at .(String , ArrayList )
at .()
at .(Stream )
at .(String , Stream , LoadOptions )
at Aspose.Cells.Workbook.(String , LoadOptions )

As for me, there are no any places in them that could raise such error. Similar htmls are loaded without problem. Could you please explain what’s the problem?

@23W,
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

CELLSNET-46955 – HTML to Excel file raises exception “Item has already been added”

1 Like

@23W,
This is to inform you that we have fixed your issue (logged earlier as “CELLSNET-46955”) now. We will soon provide you the fixed version after performing QA and incorporating other enhancements and fixes.

@23W,

Please try our latest version/fix: Aspose.Cells for .NET v19.10.4 (attached)
Aspose.Cells19.10.4 For .Net2_AuthenticodeSigned.Zip (5.0 MB)
Aspose.Cells19.10.4 For .Net4.0.Zip (5.0 MB)

Your issue should be fixed in it.

Let us know your feedback.

The issues you have found earlier (filed as CELLSNET-46955) have been fixed in Aspose.Cells for .NET v19.11. This message was posted using Bugs notification tool by Amjad_Sahi