Spire.XLS is a professional Excel API that enables developers to create, manage, manipulate, convert and print Excel worksheets. Get free and professional technical support for Spire.XLS for .NET, Java, Android, C++, Python.

Mon Jul 01, 2019 2:14 pm

Our software can no longer open workbooks.
The Line of code: workbook.LoadFromFile(filepath), generates the following error "Unexpected xml tag".

All of our company PC's were recently upgraded to Office 365, and the Spreadsheets are now manually saved by a User from Excel 365. I can only assume that this is somehow causing the Spire.XLS dll to fail.

is there a fix for this?
I can email a spreadsheet if that will help.

Thanks,
Tim Snelling
Tim.Snelling@aircompressors.com
User avatar

tsnelling
 
Posts: 14
Joined: Thu Jan 07, 2016 2:40 pm

Tue Jul 02, 2019 3:10 am

Hello,

Thanks for your inquiry.
I did an initial test with the latest Spire.XLS Pack(Hotfix) Version:9.6.12, but didn't encounter the issue you mentioned. If you were using an old version, I would suggest that you give the latest version a try, if the issue still happens, please provide your Excel file for further testing. You can attach it here or send it to our email (support@e-iceblue.com). Thanks in advance.

Sincerely,
Nina
E-iceblue support team
User avatar

Nina.Tang
 
Posts: 1187
Joined: Tue Sep 27, 2016 1:06 am

Tue Jul 02, 2019 10:45 am

I downloaded the latest Hotfix, and copied all of the Spire dll's and XML files into my Project\bin folder.
I then ran the project, but I still receive the same Error from the workbook.LoadFromFile() line of code (error description = Unexpected xml tag).
Do i need to do anything different, to test properly, with the latest Hotfix files?

If i let the project run for a few more minutes, it crashes with a Null Reference Exception.
here is the stack frame for the Null Reference Exception.
System.NullReferenceException was unhandled
HResult=-2147467261
Message=Object reference not set to an instance of an object.
Source=Spire.XLS
StackTrace:
at spr512.1(XlsWorksheet A_0, Dictionary`2 A_1)
at Spire.Xls.Core.Spreadsheet.XlsWorksheet.ParseData(Dictionary`2 dictUpdatedSSTIndexes)
at Spire.Xls.Core.Spreadsheet.XlsWorksheetBase.ParseData()
at Spire.Xls.Core.Spreadsheet.XlsWorksheet.40()
at Spire.Xls.Core.Spreadsheet.XlsWorkbook.ClearAll()
at Spire.Xls.Core.Spreadsheet.XlsWorkbook.DisposeAll()
at Spire.Xls.Core.Spreadsheet.XlsWorkbook.Close(Boolean SaveChanges, String Filename)
at Spire.Xls.Core.Spreadsheet.XlsWorkbook.Close(Boolean saveChanges)
at Spire.Xls.Core.Spreadsheet.XlsWorkbook.Close()
at Spire.Xls.Core.Spreadsheet.XlsWorkbook.Finalize()
InnerException:


I will clean out the confidential info in one of our spreadsheets, and attach it shortly.

Thanks
Tim Snelling
User avatar

tsnelling
 
Posts: 14
Joined: Thu Jan 07, 2016 2:40 pm

Tue Jul 02, 2019 11:05 am

I am now attaching a spreadsheet for your testing.

Thanks,
Tim Snelling
Attachments
2019 - test.zip
(221.22 KiB) Downloaded 186 times
User avatar

tsnelling
 
Posts: 14
Joined: Thu Jan 07, 2016 2:40 pm

Wed Jul 03, 2019 3:25 am

Hello,

Thanks for your feedback.
After testing with your sample file, I still didn't reproduce your issue. Here, I made a simple demo which I used the latest version ( Spire.XLS Pack(Hotfix) Version:9.6.12), please directly run it on your side. If your issue still occurs, please share us with your system information (E.g. Windows 7, 64 bit) and region setting (E.g. China, Chinese) to help further look into it. Look forward to your further reply.

Sincerely,
Lisa
E-iceblue support team
User avatar

Lisa.Li
 
Posts: 1261
Joined: Wed Apr 25, 2018 3:20 am

Wed Jul 03, 2019 11:00 am

I was not able to test with your Demo (could not open in VS2010). But I figured I'm missing something, and noticed the project references for the spire dll's were to a folder located in the bin folder. So I didn't place the 9.6.12 Hotfix dll's in the correct location (my bad). Once I corrected that mistake, it worked.
Thank You for your support. we will be purchasing the renewal upgrade.
Have a great day!

Tim Snelling
User avatar

tsnelling
 
Posts: 14
Joined: Thu Jan 07, 2016 2:40 pm

Thu Jul 04, 2019 1:35 am

Hello,

Glad to hear that you resolved the issue. If you encounter any issue related to our products in the future, just feel free to contact us.
Wish you all the best!

Sincerely,
Lisa
E-iceblue support team
User avatar

Lisa.Li
 
Posts: 1261
Joined: Wed Apr 25, 2018 3:20 am

Return to Spire.XLS