wood burning stoves 2.0*
The moose likes Other Open Source Projects and the fly likes how to set dependencies for jasperreports in my sample program 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 "how to set dependencies for jasperreports in my sample program" Watch "how to set dependencies for jasperreports in my sample program" New topic
Author

how to set dependencies for jasperreports in my sample program

sudheer kiran
Ranch Hand

Joined: Jun 26, 2008
Posts: 237

how to set jasper dependencies in my sample java program.
i am not using any ant task to run.

here is the exception i am getting:
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/xpath/CachedXPathAPI
at net.sf.jasperreports.engine.util.xml.XalanXPathExecuter.<init>(XalanXPathExecuter.java:45)
at net.sf.jasperreports.engine.util.xml.XalanXPathExecuterFactory.getXPathExecuter(XalanXPathExecuterFactory.java:39)
at net.sf.jasperreports.engine.util.xml.JRXPathExecuterUtils.getXPathExecuter(JRXPathExecuterUtils.java:85)
at net.sf.jasperreports.engine.data.JRXmlDataSource.<init>(JRXmlDataSource.java:172)
at net.sf.jasperreports.engine.query.JRXPathQueryExecuter.createDatasource(JRXPathQueryExecuter.java:90)
at net.sf.jasperreports.engine.fill.JRFillDataset.createQueryDatasource(JRFillDataset.java:684)
at net.sf.jasperreports.engine.fill.JRFillDataset.initDatasource(JRFillDataset.java:605)
at net.sf.jasperreports.engine.fill.JRBaseFiller.setParameters(JRBaseFiller.java:1281)
at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:901)
at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:118)
at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:435)
at net.sf.jasperreports.engine.JasperFillManager.fillReportToFile(JasperFillManager.java:220)
at net.sf.jasperreports.engine.JasperFillManager.fillReportToFile(JasperFillManager.java:126)
at createXMLReport.JXLReport.fill(JXLReport.java:61)
at createXMLReport.JXLReport.main(JXLReport.java:25)
Caused by: java.lang.ClassNotFoundException: org.apache.xpath.CachedXPathAPI
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
... 15 more


Sudheer
SCWCD, SCJP 5
sudheer kiran
Ranch Hand

Joined: Jun 26, 2008
Posts: 237

i have included xalan-2.7.1.jar and my problem is solved. thank you all.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to set dependencies for jasperreports in my sample program
 
Similar Threads
problems in viewing jasper reports
create report with java
net.sf.jasperreports.engine.JRException: java.io.FileNotFoundException
Problem in exporting jasper report to Exel
Error while running in ecllipse.