NoSuchMethodError

Hi All,

I tried to run a simple JasperReport call from Java. I included all Jars in  iReport-3.7.2/ireport/modules/ext

but still got the following error. So what Jars' should I imported?

Thanks,

Xuefeng

/***************************************************************/

 

Exception in thread "main" java.lang.NoSuchMethodError: net.sf.jasperreports.engine.component.DefaultComponentManager.setDesignConverter(Lnet/sf/jasperreports/engine/component/ComponentDesignConverter;)V
    at net.sf.jasperreports.components.ComponentsExtensionsRegistryFactory.<clinit>(ComponentsExtensionsRegistryFactory.java:98)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:247)
    at net.sf.jasperreports.engine.util.JRClassLoader.loadClassForRealName(JRClassLoader.java:161)
    at net.sf.jasperreports.engine.util.JRClassLoader.loadClassForName(JRClassLoader.java:119)
    at net.sf.jasperreports.engine.util.ClassUtils.instantiateClass(ClassUtils.java:57)
    at net.sf.jasperreports.extensions.DefaultExtensionsRegistry.instantiateRegistry(DefaultExtensionsRegistry.java:211)
    at net.sf.jasperreports.extensions.DefaultExtensionsRegistry.loadRegistries(DefaultExtensionsRegistry.java:188)
    at net.sf.jasperreports.extensions.DefaultExtensionsRegistry.loadRegistries(DefaultExtensionsRegistry.java:141)
    at net.sf.jasperreports.extensions.DefaultExtensionsRegistry.getRegistries(DefaultExtensionsRegistry.java:127)
    at net.sf.jasperreports.extensions.DefaultExtensionsRegistry.getExtensions(DefaultExtensionsRegistry.java:104)
    at net.sf.jasperreports.engine.component.ComponentsEnvironment.findComponentBundles(ComponentsEnvironment.java:94)
    at net.sf.jasperreports.engine.component.ComponentsEnvironment.getCachedComponentBundles(ComponentsEnvironment.java:82)
    at net.sf.jasperreports.engine.component.ComponentsEnvironment.getComponentBundles(ComponentsEnvironment.java:70)
    at net.sf.jasperreports.engine.xml.JRReportSaxParserFactory.getSchemaLocations(JRReportSaxParserFactory.java:162)
    at net.sf.jasperreports.engine.xml.JRReportSaxParserFactory.configureParser(JRReportSaxParserFactory.java:143)
    at net.sf.jasperreports.engine.xml.JRReportSaxParserFactory.createParser(JRReportSaxParserFactory.java:108)
    at net.sf.jasperreports.engine.xml.JRXmlDigesterFactory.createParser(JRXmlDigesterFactory.java:1138)
    at net.sf.jasperreports.engine.xml.JRXmlDigesterFactory.createDigester(JRXmlDigesterFactory.java:1113)
    at net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:203)
    at net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:168)
    at net.sf.jasperreports.engine.xml.JRXmlLoader.load(JRXmlLoader.java:152)
 

just4look's picture
286
Joined: Mar 6 2010 - 5:38pm
Last seen: 12 years 11 months ago

2 Answers:

It was the problem that I loaded too many jars. After I deleted most of them, it works now. However, I still can't see the report from its PDF version.
just4look's picture
286
Joined: Mar 6 2010 - 5:38pm
Last seen: 12 years 11 months ago
promisehalle2's picture
Joined: Sep 26 2022 - 9:03pm
Last seen: 4 months 1 week ago
Feedback