急急!!!jsp里JavaBean问题
我写了一个JavaBean,打包语句:package com.wing.javabean;
类名:Bean1
编译完成后把com目录(生成得)复制到WEB-INF/classes/里面,用Dreamweaver运行时出现编译错误,Tomcat提示找不到软件包:com.wing.javabean.Bean1 郁闷之极。。
错误提示如下:
HTTP Status 500 -
--------------------------------------------
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 2 in the jsp file: /WingTest/testJavaBean.jsp
Generated servlet error:
[javac] Compiling 1 source file
D:\Tomcat 5.0\work\Catalina\localhost\J2eeTest\org\apache\jsp\WingTest\testJavaBean_jsp.java:43: 软件包 com.wing.javabean 不存在
com.wing.javabean.Bean1 calculator = null;
^
An error occurred at line: 2 in the jsp file: /WingTest/testJavaBean.jsp
Generated servlet error:
D:\Tomcat 5.0\work\Catalina\localhost\J2eeTest\org\apache\jsp\WingTest\testJavaBean_jsp.java:45: 软件包 com.wing.javabean 不存在
calculator = (com.wing.javabean.Bean1) pageContext.getAttribute( "calculator ", PageContext.REQUEST_SCOPE);
^
An error occurred at line: 2 in the jsp file: /WingTest/testJavaBean.jsp
Generated servlet error:
D:\Tomcat 5.0\work\Catalina\localhost\J2eeTest\org\apache\jsp\WingTest\testJavaBean_jsp.java:47: 软件包 com.wing.javabean 不存在
calculator = new com.wing.javabean.Bean1();
^
3 错误
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:127)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:351)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:415)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:458)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
org.apache.jasper.JspCompilation