Hi,
Right now in our application we do not want to deal with password protected spreadsheets. At the moment, we have to include bouncycastle libraries.
Otherwise, if I do not have bouncycastle, Aspose 8.4.1 throws:
java.lang.NoClassDefFoundError: org/bouncycastle/jce/provider/BouncyCastleProvider
at com.aspose.cells.zqe.a(Unknown Source) ~[cells-8.4.1.jar:8.4.1.0]
at com.aspose.cells.zqe.a(Unknown Source) ~[cells-8.4.1.jar:8.4.1.0]
at com.aspose.cells.zqe.a(Unknown Source) ~[cells-8.4.1.jar:8.4.1.0]
at com.aspose.cells.zqe.a(Unknown Source) ~[cells-8.4.1.jar:8.4.1.0]
Is there a way I can check if an excel file is protected BEFORE aspose throws an Error? I don’t want to have to wrap a try/catch statement to catch FileNotFound/ClassNotFound exception - if anything, it would be more helpful if Aspose threw a custom exception. I’d rather gracefully exit than have to catch an exception.
But ideally, I’d like to be able to NOT include bouncycastle. Right now I am including it for the possibility of dealing with password protected spreadsheets to avoid this exception which seems a bit silly.
Thanks!