Hi,
I am facing problem while accessing bean using useBean tag. From my
servlet I am doing following
TestBean tbean1 = new TestBean();
TestBean tbean2 = new TestBean();
tBean1.setName("Fisrt Bean");
tBean2.setName("Secound Bean");
request.setAttribute("tBean1", tBean1);
request.setAttribute("tBean2", tBean2);
RequestDispatcher rd =
getServletContext().getRequestDispatcher("Test.jsp");
rd.forward(request, response);
In my JSP:
<jsp:useBean id="tBean1" class="TestBean" scope="request"/>
<jsp:useBean id="tBean2" class="TestBean" scope="request"/>
Now if I display the Name:
TBean1: Name <%= tBean1.getName() %>
TBean2: Name <%= tBean2.getName(); %>
Both are displaying "Second Bean", instead it should display:
TBean1: Name First Bean
TBean2: Name Secound Bean
Am I missing something?
Thanks in advance.
Sushil
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html