glassesbamboo Posted September 7, 2009 Share Posted September 7, 2009 JasperReport 3.6.0When i run follow code:I got Exception--jasperDesign---Exception in thread "main" java.lang.AbstractMethodError: org.codehaus.groovy.control.CompilationUnit$ClassgenCallback.call(Lorg/objectweb/asm/ClassVisitor;Lorg/codehaus/groovy/ast/ClassNode;)Vat org.codehaus.groovy.control.CompilationUnit$10.call(CompilationUnit.java:727)at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:924)at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:462)at net.sf.jasperreports.compilers.JRGroovyCompiler.compileUnits(JRGroovyCompiler.java:84)at net.sf.jasperreports.engine.design.JRAbstractCompiler.compileReport(JRAbstractCompiler.java:188)at net.sf.jasperreports.engine.JasperCompileManager.compileReport(JasperCompileManager.java:215)at Test.main(Test.java:16)I change groovy jar file from 1.0 to 1.6.What can i do.Thank you.Code:public class Test { public static void main(String args[]) throws Exception { File file = new File("c:\\test.jrxml"); System.out.println(file.exists()); JasperDesign jasperDesign = JRXmlLoader.load(file); System.out.print("--jasperDesign---"); JasperReport jasperReport = JasperCompileManager .compileReport(jasperDesign); }} Link to comment Share on other sites More sharing options...
glassesbamboo Posted September 8, 2009 Author Share Posted September 8, 2009 I fixed this problem. unpackage jar file from jasperreports-3.6.0-project.zip is fine. Link to comment Share on other sites More sharing options...
itzbobi Posted September 11, 2009 Share Posted September 11, 2009 hi, i am bobby. I too have a similar error with the new version of ireport3.6.0 My program has compiled without errors. But facing runtime error : Exception in thread "main" java.lang.AbstractMethodError: org.codehaus.groovy.control.CompilationUnit$ClassgenCallback.call(Lorg/objectweb/asm/ClassVisitor;Lorg/codehaus/groovy/ast/ClassNode;)V at org.codehaus.groovy.control.CompilationUnit$10.call(CompilationUnit.j ava:727) at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes( CompilationUnit.java:924) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.j ava:462) at net.sf.jasperreports.compilers.JRGroovyCompiler.compileUnits(JRGroovy Compiler.java:88) at net.sf.jasperreports.engine.design.JRAbstractCompiler.compileReport(J RAbstractCompiler.java:192) at net.sf.jasperreports.engine.JasperCompileManager.compileReport(Jasper CompileManager.java:219) at Jreport.main(Jreport.java:65) Link to comment Share on other sites More sharing options...
itzbobi Posted September 11, 2009 Share Posted September 11, 2009 itzbobiWrote: hi, i am bobby. I too have a similar error with the new version of ireport3.6.0 My program has compiled without errors. But facing runtime error : Exception in thread "main" java.lang.AbstractMethodError: org.codehaus.groovy.control.CompilationUnit$ClassgenCallback.call(Lorg/objectweb/asm/ClassVisitor;Lorg/codehaus/groovy/ast/ClassNode;)V at org.codehaus.groovy.control.CompilationUnit$10.call(CompilationUnit.j ava:727) at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes( CompilationUnit.java:924) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.j ava:462) at net.sf.jasperreports.compilers.JRGroovyCompiler.compileUnits(JRGroovy Compiler.java:88) at net.sf.jasperreports.engine.design.JRAbstractCompiler.compileReport(J RAbstractCompiler.java:192) at net.sf.jasperreports.engine.JasperCompileManager.compileReport(Jasper CompileManager.java:219) at Jreport.main(Jreport.java:65) Code:i have included the following jar's to environment varialble list..;F:all jarsservlet-api.jar;F:all jarsmysql-connector-java-5.1.5-bin.jar;F:all jarsjasperreports-3.5.0.jar;F:all jarsiText-2.1.7.jar;F:all jarscommons-digester-2.0.jar;F:all jarscommons-logging-1.1.1.jar;F:all jarscommons-collections-3.2.1.jar;F:all jarscommons-digester-2.0.jar;F:all jarscommons-beanutils-1.8.0.jar;F:all jarsgroovy-1.6.4.jar;F:all jarsasm-all-2.2.jar;F:all jarsantlr-2.7.7.jar;F:all jarsxercesImpl-2.7.0.jar;F:all jarsgroovy-all-1.1-rc-1.jar; Link to comment Share on other sites More sharing options...
glassesbamboo Posted September 11, 2009 Author Share Posted September 11, 2009 My IDE is Eclise. I unpackage jasperreports-3.6.0-project.zip,import jar file from /lib and /dist. and run your program once again. good luck. Link to comment Share on other sites More sharing options...
itzbobi Posted October 5, 2009 Share Posted October 5, 2009 Thank you for the solution. I was not using any IDE , so just copied all the jars into jdk/lib/ext folder. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now