Excel to pdf in webapplication

Ls,


I am trying to convert excel documents to pdf with the following code in an webapplication:
Workbook wb = new Workbook(sourceFile);
PdfSaveOptions pso = new PdfSaveOptions();
pso.setPrintingPageType(PrintingPageType.DEFAULT);
pso.setCompliance(PdfCompliance.PDF_A_1_B);
wb.save(outPutFile, pso);

But this result in an “java.lang.Exception: java.lang.NoClassDefFoundError

I have the same kind of error with converting powerpoint documents to pdf and have mentioned this here:
Powerpoint to pdf in webapplication

I am running on windows 7, with jboss 6.0.0

Hi,

Thanks for your posting and using Aspose.Cells for Java.

Please add all the jars which are needed by Aspose.Cells in your class path. Adding them in your class path will resolve your issue.

Following are the jar files required by Aspose.Cells for your help. You can find them in the zip archive of download.

  1. bcprov-jdk16-146.jar
  2. dom4j-1.6.1.jar
  3. stax2-api-3.0.2.jar
  4. woodstox-core-asl-4.1.1.jar

In my initial post i refered to a post i made in the slides forum.

My problem wiht the slides library is the same.
I have all the necessary libraries in teh classpath but still get the following error:
java.lang.Exception: java.lang.NoClassDefFoundError: com/aspose/cells/gW (wrong name: com/aspose/cells/gw)
Hi,

Thanks for your posting and using Aspose.Cells for Java.

It should be a bug of jboss6.0. This version of jboss cannot treat java classes as case sensitive. Please upgrade jboss to newer version and this problem should be resolved.

Ls,

Does this mean you are not assigning this as a defect and try to resolve this within the aspose library? with the powerpoint library they did assign it as a defect and created a fix.

Regards,

Jasper

Hi,

Thanks for your posting and using Aspose.Cells for Java.

Please follow the instructions in previous post. You must upgrade jboss version. It should resolve your issue. If it does not resolve your issue, please let us know. We will look into your issue and help you asap.

We can not upgrade the jboss environment.

We have other software(applications) running on it and they require this jboss version.

Does this mean, there will not be a fix with Aspose.Cells?

Regards,

Jasper

Hi,

Thanks for your posting and considering Aspose.Cells for Java.

We have logged your comments in our database. We will look into your issue and help you asap. This issue has been logged as CELLSJAVA-40471.

Once we have any update relating to this issue, we will share it with you asap.

LS,

Any thoughts on when this issue will be resolved?

Regards,

Jasper

Hi,

Thanks for your posting and using Aspose.Cells.

We have logged your comments in our database. Once, we will have some update for you, we will share it with you asap.

LS,

first of all, my problem is with the java version of Aspose.Cells.

With version 7.4.3.1 of Aspose.Cells for java i now get the following exception:

java.lang.Exception: java.lang.NoClassDefFoundError: com/aspose/cells/gX (wrong name: com/aspose/cells/gx)

Regards,

Jasper

Hi,

Thanks for your posting and using Aspose.Cells for Java

We have attached the java version.

Please download and try this fix: Aspose.Cells for Java v7.4.3.1 and let us know your feedback.

As i already mentioned:

With version 7.4.3.1 of Aspose.Cells for java i now get the following exception:

java.lang.Exception: java.lang.NoClassDefFoundError: com/aspose/cells/gX (wrong name: com/aspose/cells/gx)

Hi,

Thanks for your posting and using Aspose.Cells.

We have logged your comments in our database against this issue. We will look into your issue and get back to you asap.

Hi,

Thanks for your posting and using Aspose.Cells.

We have tested the fix 7.4.3.1 with JBoss6.0 and cannot find such kind of issue. With the fix we can open template files and save them fine. Please make sure you have deployed the right jar to your web application. And if you get this error with special template files, please send us your sample code to reproduce the issue(such as an jsp file that can run with the server to reproduce the issue).

LS,


Attached is a Test.zip, which contains a Test.jsp file i used on aspose-cells-7.4.3
the result of the jsp is that it gives me the following error:
javax.servlet.ServletException: java.lang.NoClassDefFoundError: com/aspose/cells/gX (wrong name: com/aspose/cells/gx)
Regards,
Jasper

Hi,

Thanks for your posting and using Aspose.Cells for Java.

We have logged your comment in our database along with your test.zip file. We will look into your issue and once, we will have some update for you, we will let you know asap.

Hi,

Thanks for your posting and using Aspose.Cells for Java.

Would you please confirm whether you have deployed the correct jar to your application? You can just print out the version number of the jar(CellsHelper.getVersion()) to confirm this. We cannot reproduce the issue even with your jsp code.

Hi,


I added the version check to the test.jsp and got 7.4.3.0
attached is a part of the logfile and the new jsp

regards,

Jasper

Hi,

Thanks for your posting and using Aspose.Cells for Java.

We have logged your comments in our database. Once, we will have some update relating to your issue, we will let you know asap.