This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Other Open Source Projects and the fly likes eroor when exportReportToPdfFile Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "eroor when exportReportToPdfFile " Watch "eroor when exportReportToPdfFile " New topic
Author

eroor when exportReportToPdfFile

vasu hk
Greenhorn

Joined: Oct 29, 2009
Posts: 2
Hi,
I have used the code fragment mentioned below to view the report and export to PDFfile in NetBeans 6.1 (the report is originally generated and compiled using iReport 3.6.0),my requirement is to export in to pdf using jsp application ,i have used the latest iText2.1.0 jar file in my application ,still i getting the exception , please help me .

code:



Exception :

javax.servlet.ServletException: Servlet execution threw an exception

root cause

java.lang.NoSuchMethodError: com.lowagie.text.pdf.PdfWriter.setRgbTransparencyBlending(Z)V
net.sf.jasperreports.engine.export.JRPdfExporter.exportReportToStream(JRPdfExporter.java:480)
net.sf.jasperreports.engine.export.JRPdfExporter.exportReport(JRPdfExporter.java:379)
net.sf.jasperreports.engine.JasperExportManager.exportReportToPdfFile(JasperExportManager.java:122)
ReportServlet.processRequest(ReportServlet.java:104)
ReportServlet.doGet(ReportServlet.java:142)
javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

Hi there and welcome to Javaranch!

Have you double checked your CLASSPATH and that the JARs actually contain that class/method?


Cheers, Martijn - Blog,
Twitter, PCGen, Ikasan, My The Well-Grounded Java Developer book!,
My start-up.
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24183
    
  34

That's the sort of error you can get if the version of iReport you use when you compile the code is different from the version that's present in the application server environment. Make sure that both your IDE and your deployment environment are using the same versions of all libraries.


[Jess in Action][AskingGoodQuestions]
Mike Rzzzz
Greenhorn

Joined: Sep 20, 2011
Posts: 1
Just change the server to GlassFish.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: eroor when exportReportToPdfFile
 
Similar Threads
Error when exportReportToPdfFile
Jasper Reports Exception
[Jasper Reports] Export PDF file, I'm crazying!
Jasper Exception
how to generate dynamic reports in java