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.

Fri Jan 11, 2019 11:02 pm

I am trying to convert a .xls file to .xlsx but all of the formatting is lost during the conversion. Here is the code:

Code: Select all
Spire.Xls.Workbook workbook = new Spire.Xls.Workbook();
workbook.LoadFromStream(cdfStream);
workbook.SaveToFile(filePathName, ExcelVersion.Version2013);


It doesn't matter which ExcelVersion I choose. This is how the conversion looks:
screenshot.png
screenshot.png (24.99 KiB) Viewed 936 times


The data is coming from a 3rd party database so that is why the code sample has the data loaded as a stream. It doesn't matter if I export to a file first, the same thing happens. Attached is the raw file from the database.

The 3rd party application hides the workbook so you have to click the View menu in Excel and click Unhide to view the data. The conversion automatically unhides the data which is perfectly fine.

Any help would be appreciated.
Attachments
PreRequisite_1.zip
(8.29 KiB) Downloaded 178 times

bungeemann
 
Posts: 2
Joined: Fri Jan 11, 2019 10:20 pm

Mon Jan 14, 2019 2:37 am

Hi,

Thank you for your inquiry.
I have reproduced the issue and logged it in our bug tracking system. Once it is fixed, I will let you know.
Sorry for the inconvenience caused!

Sincerely,
Jane
E-iceblue support team
User avatar

Jane.Bai
 
Posts: 1156
Joined: Tue Nov 29, 2016 1:47 am

Sun Jan 20, 2019 5:16 pm

Thank you. I'll be interested if this can be fixed.

bungeemann
 
Posts: 2
Joined: Fri Jan 11, 2019 10:20 pm

Mon Jan 21, 2019 1:55 am

Hi,

Sorry that the issue is not resolved at present. And I got information from our Dev team that the issue is very complex and it would not be fixed in a short time. Anyway, we will inform you as soon as there is any good news.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy.jiang
 
Posts: 3099
Joined: Tue Sep 06, 2016 8:30 am

Return to Spire.XLS