Exception "Invalid string in the file" while opening XLS file using Aspose.Cells for .NET in C#

Hi,

I’m using Aspose.Cells for .NET version 17.9.0.0. And I have an XLS file, please see attachment. The library fails to open it, although MS Excel 2016 (Windows) opens it up with no issues.

I’m getting following error message and stack-trace:

Invalid string in the file.

at .()
at .( )
at . ( )
at .(MemoryStream )
at .( )
at .( )
at Aspose.Cells.Workbook.(Stream , LoadOptions , Boolean )
at Aspose.Cells.Workbook…ctor(Stream stream)
at ExcelUtilities.ValidFileCustomProperties(Byte[] excelFile) in
C:\GIT\MyProject1\ExcelUtilities.cs:line 25

File with the issue:
Example.zip (535.7 KB)

@EMSMS

Thanks for using Aspose APIs.

We were able to observe the exception while opening your provided XLS file. We have logged this issue in our database for further investigation and for a fix. Once, the issue is resolved or we have some other news for you, we will let you know asap.

This issue has been logged as

  • CELLSNET-46008 - Invalid string in the file - exception occurs on opening the XLS file

@EMSMS

Thanks for using Aspose APIs.

Please download and try the following fix and let us know your feedback.

@shakeel.faiz,

I was unable to try 18.3.3, but I tried 18.3.0.0, and it errors out the same as 17.9.0.0 which I currently use.

Cheers

@EMSMS,

Why you could not try our latest version/fix: Aspose.Cells for .NET v18.3.3? Please note, Aspose.Cells for .NET v18.3 does not fix your issue but v18.3.3 fixes your issue, so kindly try it and let us know how it goes on your end.

Hi @Amjad_Sahi,

I tried 18.3.0.0 since it is the latest version available on NuGet Gallery | Aspose.Cells 18.3.0

Do you know whether 18.3.3 will be available there? And if yes, when?

Cheers

@EMSMS,

Well, we publish official releases only on Nuget/maven repos., we do not publish fixes over there. We publish official release of the product once in a month. So, either you may use the fix for now or wait for our next official release of the product (Aspose.Cells for .NET v18.4 - it will include all previous fixes and other enhancements). Our next official release is due in the third or fourth week of April 2018.

@Amjad_Sahi

Thank you!

Hi @Amjad_Sahi,

One more thing, few actually…

  1. Could you please let me know what sheet & cell in the attached file is causing the issue?
  2. Is it possible to move up the release date for version 18.4?

Cheers

@EMSMS

MS Excel gathers all strings into a pool. The count of the string pool is wrong in the file.

We are looking into uploading the fix to NuGet.

The issues you have found earlier (filed as CELLSNET-46008) have been fixed in Aspose.Cells for .NET 18.4. Please also check the document/article for your reference: Install Aspose Cells through NuGet|Documentation