Hi,
We are getting a NullPointerException when attempting to create a Workbook instance for the attached file, using aspose-cells 17.5:
try {
InputStream stream = new FileInputStream(fileName);
new Workbook(stream);
} catch (Exception e) {
e.printStackTrace();
}
Here is the stacktrace:
java.lang.NullPointerException
at com.aspose.cells.FillFormat.a(Unknown Source)
at com.aspose.cells.zkb.c(Unknown Source)
at com.aspose.cells.zkb.a(Unknown Source)
at com.aspose.cells.zkb.a(Unknown Source)
at com.aspose.cells.zkb.a(Unknown Source)
at com.aspose.cells.zaps.a(Unknown Source)
at com.aspose.cells.zaps.b(Unknown Source)
at com.aspose.cells.zbzu.O(Unknown Source)
at com.aspose.cells.zbzu.ak(Unknown Source)
at com.aspose.cells.zbzu.a(Unknown Source)
at com.aspose.cells.zbzu.c(Unknown Source)
at com.aspose.cells.zbzu.b(Unknown Source)
at com.aspose.cells.Workbook.a(Unknown Source)
at com.aspose.cells.Workbook.(Unknown Source)
Please help us resolve this issue.
Regards,
Oana
Hi,
Thanks for your posting and using Aspose.Cells.
We were able to observe the exception as per your description while loading your Excel file in a Workbook object. We tested this issue with the most recent version.
We have logged this issue in our database for investigation and for a fix. Once, the issue is resolved or we have some other update for you, we will let you know asap.
This issue has been logged as
-
CELLSJAVA-42302 - NullPointerException on creating Workbook instance from source Excel file
Thank you! We're looking forward to a resolution.
Have a great day!
Hi,
Thanks for using Aspose.Cells.
This is to inform you that we have fixed your issue CELLSJAVA-42302 now. We will soon provide the fix after performing QA and including other enhancements and fixes.
Hi,
Thank you, we’re looking forward to the fix.
We’ve also been seeing a few NullPointerExceptions logged by our product in production, they also occur during Workbook instantiation, but we can only provide the stack trace, since we do not have access to the customer’s files.
The version of Aspose-Cells for the following stack traces is 17.3.0:
Caused by: java.lang.NullPointerException
at com.aspose.cells.zakr.a(Unknown Source)
at com.aspose.cells.zald.p(Unknown Source)
at com.aspose.cells.zald.d(Unknown Source)
at com.aspose.cells.zalc.a(Unknown Source)
at com.aspose.cells.Workbook.a(Unknown Source)
at com.aspose.cells.Workbook.(Unknown Source)
Caused by: java.lang.NullPointerException
at com.aspose.cells.zcfp.c(Unknown Source)
at com.aspose.cells.zcfp.a(Unknown Source)
at com.aspose.cells.zcfz.j(Unknown Source)
at com.aspose.cells.zcfz.e(Unknown Source)
at com.aspose.cells.zcfz.a(Unknown Source)
at com.aspose.cells.Workbook.a(Unknown Source)
at com.aspose.cells.Workbook.(Unknown Source)
Since the code is obfuscated, we are unable to tell if this is the same exception as the one I reported in my first post. Could you please look into these as well?
Thank you in advance!
Oana
Hi,
Well, the exception “java.lang.NullPointerException” can be template specific. Please wait for the next fix, hopefully the fix would also resolve the issue for your other files. But, if the upcoming fix does not resolve the issue for some of your other files, I am afraid, we would need your template file(s) to evaluate and resolve the issue.
Thank you.
Thank you!
Perhaps some improvements in the Aspose Cells logging mechanism would make it easier to identify the causes for such exceptions. Unfortunately, we cannot always get the templates. Hopefully the next fix will resolve the issues encountered by our customers as well.
Hi,
Thanks for using Aspose.Cells.
Hi!
Thank you for the quick response! We have tested the library you provided and can confirm that it fixes the bug we reported.
Will this fix be included in the next Aspose Cells release? When will it be available?
Best regards,
Oana
The issues you have found earlier (filed as CELLSJAVA-42302) have been fixed in Aspose.Cells for Java (Download Section).
This message was posted using Notification2Forum from Downloads module by Aspose Notifier.