NoClassDefFoundError: com/lowagie/text/DocumentException

I am get following exception.

Exception in thread "main" java.lang.NoClassDefFoundError: com/lowagie/text/DocumentException at net.sf.jasperreports.engine.JasperExportManager.exportReportToPdf(JasperExportManager.java:183) at net.sf.jasperreports.engine.JasperRunManager.runReportToPdf(JasperRunManager.java:305)  at Report.main(Report.java:45)

Help me asap.

Related Post

Error in setting up Quartz (Spring framework)
java.lang.NoClassDefFoundError: org/apache/commons/codec/DecoderException
nested exception is java.lang.NoClassDefFoundError: net/sf/ezmorph/Morpher
nested exception is java.lang.NoClassDefFoundError: org/apache/poi/hssf/usermodel /HSSFCellStyle
nested exception is java.lang.NoClassDefFoundError: org/apache/poi/hssf/usermodel /HSSFCellStyle

Comments

4 Responses to “NoClassDefFoundError: com/lowagie/text/DocumentException”

  1. Armada on October 26th, 2009 11:14 pm

    You are missing itext.jar in project’s build path. This jar can be downloaded from http://prdownloads.sourceforge.net/itext

  2. Gautam on December 6th, 2009 2:24 am

    Since you are getting NoClassDefFoundError and not ClassNotFoundException, it means the JAR is there in your classpath but classloader is not able to load this class. May be due to version mismatch. Like you are using JDK1.4 and trying to use a class complied in JDK1.5 or above version. Link might help:
    http://www.jroller.com/sjivan/entry/difference_between_classnotfoundexception_and_noclassdeffounderror

  3. Rao on December 15th, 2010 4:56 am

    Gautam, thanks.

  4. Shihad on January 25th, 2011 2:44 pm

    Hi Gautam,
    I am also getting the same exception-“NoClassDefFoundError: com/lowagie/text/DocumentException”
    I added iText jars. I am using JDK 1.6. Can you please solve my problem.

    Thanks,
    Shihad

Leave a Reply