I am getting the following exception when trying to load an Excel file. I am able to open the same file in MS Excel without any problem. I am using the Aspose cells for Java version 19.8.
com.aspose.cells.CellsException: Error for ZipFile
at com.aspose.cells.zbaq.a(Unknown Source)
at com.aspose.cells.a.f.zj.(Unknown Source)
at com.aspose.cells.a.f.zj.a(Unknown Source)
at com.aspose.cells.zrz.a(Unknown Source)
at com.aspose.cells.zjp.a(Unknown Source)
at com.aspose.cells.zjp.a(Unknown Source)
at com.aspose.cells.Workbook.a(Unknown Source)
at com.aspose.cells.Workbook.(Unknown Source)
If i open the file in any excel tool (MS Excel) and save it as new or modify and save the same file, then the new file/modified file is working fine when parse using aspose-cells.
I am not able to share the excel file as it contains sensitive data. Please advice.
If your issue still occurs with Aspose.Cells for Java v23.6, then please provide us your source Excel file which is causing this exception. We will look into it and try to figure it out soon.
Good to know that latest version fixes out your issue. Feel free to contact us any time if you need further help or have some other issue or queries, we will be happy to assist you soon.
Hi @amjad.sahi we are using Aspose cells for Java version 23.6 to create xlsx file. Everything is fine but the size of the file is different for every file we generated using the same data.
@sankar1217,
An Excel file may contain one or multiple sheet pages. Each sheet page has a unique ID, and due to differences in unique IDs, there may be extremely subtle differences after compression. Please refer to the attachment (228.1 KB).
@John.He Is that this unique ID for each sheet is something which introduced in 20.3 version ? Because in 19.8 version we don’t find any size difference.
@sankar1217
Through testing with sample code, we can reproduce the issue. It was found that when executing the same code multiple times, the generated file may have different sizes.
This may be due to the compression algorithm. Anyway, we will create a ticket for research and notify you immediately once there are updates.
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): CELLSJAVA-45594
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.
@sankar1217
We supported unique ID for each sheet in 2020. The size of file will be different for different sheet’s ID.
If you do not need the unique ID of the sheet and want to keep the file same size, please remove it as the following codes: