Hi Folks,

I'm written a DispatchAction and written a methode that initialize a
FormBean that I use.
How do I populate so that the JSP-Taglibs cann access it? 

I tried following ideas:

1) Adding it as HttpSession attribute using the name of the FormBean as key
and the form instance as value. that failes


        form = new UserForm();

        ... // some assings here 
                
        request.getSession().setAttribute("user", form);

        return mapping.findForward( ForwardSuite.USER_SHOW );
        

2) I added it to the request in the same manner as I did it with the session
before.

Is this correct or do I missunderstand the usage of DispatchAction? If
correct I guess I'm using the html taglibs incorreclty, am I?

Here some information:

scope: session
servlet-container: tomcat/catalina as plugin of jboss
tag used to accees: html:form

javax.servlet.jsp.JspException: Cannot retrieve definition for form bean
UserForm
        at org.apache.struts.taglib.html.FormTag.lookup(FormTag.java:897)
        at
org.apache.struts.taglib.html.FormTag.doStartTag(FormTag.java:543)
        at org.apache.jsp.user$jsp._jspService(user$jsp.java:126)
        at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja
va:202)
        at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:382)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.
java:683)
        at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatch
er.java:431)
        at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher
.java:355)
        at
org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:10
14)
        at
org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProces
sor.java:417)
        at
org.apache.struts.action.RequestProcessor.processActionForward(RequestProces
sor.java:390)
        at
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:271)
        at
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1292)
        at
org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492)

Thank you for your help and patience.

Bye
Toby

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to