Hi all,
I'm trying the example below:

hellouser.jsp
<%@ page import="hello.NameHandler" %>
<jsp:useBean id="abean" scope="page" class="hello.NameHandler" />
<jsp:setProperty name="abean" property="*" />
<html>
<head><title>Hello, User</title></head>
<body bgcolor="#ffffff" background="background.gif">
<%@ include file="dukebanner.html" %>
<table border="0" width="700">
<tr>
<td width="150"> &nbsp; </td>
<td width="550">
<h1>My name is Duke. What's yours?</h1>
</td>
</tr>
<tr>
<td width="150" &nbsp; </td>
<td width="550">
<form method="get">
<input type="text" name="username" size="25">
<br>
<input type="submit" value="Submit">
<input type="reset" value="Reset">
</td>
</tr>
</form>
</table>
<%
 if ( request.getParameter("username") != null ) {
%>
<%@ include file="response.jsp" %>
<%
 }
%>
</body>
</html>

dukebanner.html
<table border="0" width="400" cellspacing="0" cellpadding="0">
<tr>
<td height="150" width="150"> &nbsp; </td>
<td width="250"> &nbsp; </td>
</tr>
<tr>
<td width="150"> &nbsp; </td>
<td align="right" width="250">
<img src="duke.waving.gif">
</td>
</tr>
</table>
<br>

NameHandler.java
package hello;

public class NameHandler {

 private String username;

 public NameHandler() {
  username = null;
 }

 public void setUsername( String name ) {
  username = name;
 }

 public String getUsername() {
  return username;
 }
}


response.jsp
<table border="0" width="700">
<tr>
<td width="150">
&nbsp;
</td>
<td width="550">
<h1>Hello, <jsp:getProperty name="abean" property="username" />!
</h1>
</td>
</tr>
</table>

When I try and open the hellouser.jsp page, I'm
getting the following error. Where am I going wrong?

JSP Error:

----------------------------------------------------------------------------
----



Request URI:/ifp/testjsp/hello/hellouser.jsp

Exception:
oracle.jsp.parse.JspParseException: Line # 3, Error: Unable to find class
for bean: abean defined by tag with class: hello.NameHandler



----------------------------------------------------------------------------
----



Thanks in advance.
S. Jyotinarayan

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to