How can i Instantiate a bean in a
servlet and latter read it from
jsp using the use bean tag .
My code :
ResultBean rb= new ResultBean();
rb.setaName(Acc.getName());
rb.setaIATA(Acc.getIATA());
PageContext pagecontext = JspFactory.getDefaultFactory().getPageContext(this, request, response, null, true, 8192, true);
pagecontext.setAttribute("rb", rb);
//request.setAttribute("resultdata", rb);
System.out.println(" hi ----in servlet ------------"+Acc.getIATA());
srd = request.getRequestDispatcher("results.jsp");
In jsp i want to use the use bean tag
<jsp:useBean id="rb" class="result.ResultBean" scope="request"/>
i am not getting any value in the jsp page no error is also being shown .
How can i do what is required .
Thanks ,
Tirthankar