Hi,
I faced a problem while developing a strut application.
I am explaining in details.
In my action class I defined an object which is as follows
public ActionForward perform(
ActionMapping mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response)
throws IOException, ServletException {
--------------------
---------------------
Department dept =new Department();
dept.setDno(dno);
request.setAttribute("DEPARTMENT",dept);
if(dept.getFlag())
forward= mapping.findForward("success");
else
forward= mapping.findForward("failure");
return forward;}
But I am unable to access in succes.jsp
<%@ page import="deptPack.Department"%>
and when i wrote
<%=(Department(request.getAttribute("DEPARTMENT"))).getName() %>
The following eror is coming during compilation
"the method defined Department is undefined for the type succes
Please help me.
Thanks in advance
Sidhartha das