Hello
I have been trying for too long to get this simply to
work.  Below is very simple code that fails at the
first attempt to retrieve the form bean method.  What
can possibly be wrong, it gives compiles, gives a NPE.
 The form bean variables are ="" in the reset method.
I do know how to do it as the example further below
works fine.  Please advise.

public class search1Action extends Action {
    public ActionForward execute(ActionMapping
actionMapping,
                                 ActionForm form,
                                 HttpServletRequest
request,
                                 HttpServletResponse
response) {
        header1Form header1Form_ = (header1Form) form;
        String queryString =
((header1Form)form).getQuery();
        String animalType =
((header1Form)form).getAnimalType();

This works fine:
public class min01Action extends Action {
    public ActionForward execute(ActionMapping
actionMapping,
                                 ActionForm form,
                                 HttpServletRequest
request,
                                 HttpServletResponse
response) {

        min01Form min01Form_ = (min01Form)form;
        String fromAction =
((min01Form)form).getSample().toUpperCase();
        String fromAction2 =
((min01Form)form).getSample2().toUpperCase();
        HttpSession session = request.getSession();
        session.setAttribute("fromAction",fromAction);
       
session.setAttribute("fromAction2",fromAction2);
        return (actionMapping.findForward("success"));
    }
}

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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

Reply via email to