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

Free Support Forum - aspose.com

Read and save a workbook error

Workbook wb = new Workbook("C:/migrate_BAD.xlsx");
Workbook nwb = new Workbook();
nwb.copy(wb);
nwb.save("C:/migrate2.xlsx");


Open migrate2.xlsx with ms excel 2013 will occur file format with errors

and can't open it.

Hi,

Thanks for your posting and using Aspose.Cells.

We have tested your issue with the following sample code using the latest version: Aspose.Cells
for Java v8.6.1.2
and found the issue did not occur. The generated xlsx file looks fine without any problem. I have attached the output excel file generated with the following code for a reference.

Java
String filePath = “D:/Downloads/migrate_BAD.xlsx”;

Workbook wb = new Workbook(filePath);
Workbook nwb = new Workbook();
nwb.copy(wb);
nwb.save(filePath + “.out.xlsx”);