Generated file unreadable with another API due to FilePass

Hi,
I have a slightly unusual issue which I hope you will be able to help with.

We are writing an xls file using Aspose Cells for Java, that will later be read by another API (used for automated testing). However, the file is not able to be read by the other API.
The reason seems to be that if you apply workbook.protect(ProtectionType.STRUCTURE, null) which we need to do, then the generated binary file includes a ‘FilePass’ record, which according to the xls file spec at http://msdn.microsoft.com/en-us/library/cc313154.aspx should only be added if the file is encrypted (we have not specified any encryption through Aspose).

Incidentally, by opening in Excel then saving the file, this record disappears, and the file is readable by our other api.

Thanks in advance for your help in this matter,

Simon Kelly
Agentrics LLC

Hi,


We do not add encryption options unless you apply these options explicitly using the Aspose.Cells for Java APIs. We are not completely sure about your issue if it is due to our product. Anyways, we recommend you to update to latest version/fix: Aspose.Cells for Java v7.0.3.5 (in which we made a lots of enhancements) and try it and let us know if it works fine.

Thank you.

Hi Amjad,
I’ve tried with the latest version, but I get the same result.

The problem can be demonstrated by looking at the records stored in the generated binary file. I have attached the comparison that I have run on 2 files, one generated by Aspose Cells the other a file created in Excel, protected (workbook, structure) then saved as xls 97-2003 format.

Neither file is encrypted, but the file generated by Aspose.Cells has a record called FILEPASS, which should not be there. It is this FILEPASS record that implies that the file is encrypted, and hence our other API will not read past that record.

Thanks,

Simon

Hi Simon,


Thanks for the sample files.

We need to investigate the issue thoroughly. I have logged a ticket with an id: CELLSJAVA-40062. We will look into it soon.

Thank you.


Hi,

Please download and try the new fix: Aspose.Cells for Java v7.0.3.6

Hi,

Yes this fixes the issue for us. Thanks for looking into it and for the fix.

Simon

The issues you have found earlier (filed as CELLSJAVA-40062) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.