在MyEclipse中 导入jar包不对的时候会报 jasperreport引擎的异常,engine.JRException,提示的错误如下:

 

 2012-4-23 16:56:24 org.apache.catalina.core.ApplicationContext log

信息: Marking servlet LogServlet as unavailable
2012-4-23 16:56:24 org.apache.catalina.core.StandardWrapperValve invoke
严重: Allocate exception for servlet LogServlet
java.lang.ClassNotFoundException: net.sf.jasperreports.engine.JRException
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1360)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1206)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
at java.lang.Class.getConstructor0(Class.java:2699)
at java.lang.Class.newInstance0(Class.java:326)
at java.lang.Class.newInstance(Class.java:308)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1104)
at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:806)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)

 解决方法,按如下图导入相关的jar包,导入多了也出现异常,其中的 oscarJDBC.JAR是我自己的。

 

posted on 2012-04-23 17:15  品香一郎  阅读(543)  评论(0编辑  收藏  举报