• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

Generating JasperReport in PDF

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
While generating JasperReport in PDF, I am getting following error
"main" java.lang.NoClassDefFoundError: com/lowagie/text/DocumentException
I am new to the report generation, I don't have much of knowledge about it,
so can you please help me? Please

I am using Eclipse.

I have included all related jars in path
itextpdf-5.2.0.jar,
commons-collections-3.2.1.jar,
commons-beanutils-1.8.2.jar,
commons-javaflow-20060411.jar,
commons-logging-1.1.jar,
jasperreports-4.5.0.jar,
commons-digester-1.7.jar,
groovy-all-1.7.5.jar,
classes12.jar



JasperDesign jasperDesign=JRXmlLoader.load("jrxml-file-path");
JasperReport jasperReport = JasperCompileManager.compileReport(jasperDesign);
Map parameters = new HashMap();
parameters.put("EMPNO","1234");
Connection conn = DataBase.getConnection();
JasperPrint jasperPrint = JasperFillManager.fillReport(jasperReport, parameters, conn);
JasperExportManager.exportReportToPdfFile(jasperPrint,"pdf-File-path");
 
The fastest and most reliable components of any system are those that are not there. Tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic