You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Tom Ansley <to...@linux.net> on 2004/06/10 19:45:49 UTC

Validation of dynaActionForm too early

Hi all,

I am trying to use a dynaActionForm.  The problem I am having is that 
when a user requests an action which has a dynaActionForm attached to it 
the first page the user gets from the action is a page which shows all 
the errors that the user needs to correct.

Basically the form is being validated before the user has a chance to 
enter information into the form.

How do I go about getting it so that the first time the action is called 
the validate() method is not called?

Cheers

Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Validation of dynaActionForm too early

Posted by Bill Siggelkow <bi...@bellsouth.net>.
Set validate="false" on the Action that forwards to the JSP containing 
the form. Set 'validate="true"' and set 'input="/myJsp.jsp"' for the 
action that processes the form.

Tom Ansley wrote:

> Hi all,
> 
> I am trying to use a dynaActionForm.  The problem I am having is that 
> when a user requests an action which has a dynaActionForm attached to it 
> the first page the user gets from the action is a page which shows all 
> the errors that the user needs to correct.
> 
> Basically the form is being validated before the user has a chance to 
> enter information into the form.
> 
> How do I go about getting it so that the first time the action is called 
> the validate() method is not called?
> 
> Cheers
> 
> Tom


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org