wood burning stoves 2.0*
The moose likes JSP and the fly likes unable to compile class for jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "unable to compile class for jsp" Watch "unable to compile class for jsp" New topic
Author

unable to compile class for jsp

satyasandha samal
Greenhorn

Joined: Aug 11, 2009
Posts: 5
org.apache.jasper.JasperException: Unable to compile class for JSP:

An error occurred at line: 9 in the jsp file: /loginbean.jsp
The method getUsername() is undefined for the type LoginBean
6: <jsp:setProperty name="db" property="username" value='<%=request.getParameter("username")%>'/>
7: <jsp:setProperty name="db" property="password" value='<%=request.getParameter("password")%>'/>
8: </jsp:useBean>
9: <jsp:forward page="hello">
10: <jsp:param name="username" value="<%=db.getUsername()%>" />
11: <jsp:param name="password" value="<%=db.getPassword()%>" />
12: </jsp:forward>


Stacktrace:
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:93)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:451)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:319)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:298)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:564)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:302)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
javax.servlet.http.HttpServlet.service(HttpServlet.java:729)


note The full stack trace of the root cause is available in the Apache Tomcat/5.5.28 logs.

James Ward
Ranch Hand

Joined: Apr 27, 2003
Posts: 263
The method getUsername() is undefined for the type LoginBean


So, does the LoginBean class have these methods?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: unable to compile class for jsp
 
Similar Threads
Internal Error while Validating username and password
re:tomcat error
hello help me in authentication
Login code problem getting some HTTP Status 404 error
Unable to compile class for JSP