If the forward isn't a redirect you shouldn't need to
repopulate the form. This use-case, btw, is what
"mapping.getInputForward()" is for (along with the
"input" attribute of the action configuration
element).
d.
--- debussy007 <[EMAIL PROTECTED]> wrote:
>
> Hello,
>
> When the user submits my form,
> I retrieve it as a DynaActionForm, do some checks in
> execute() method,
> and if the form submitted is not valid,
> I want to forward to the form again and repopulate
> the form with the
> inserted values.
>
> How can I achieve this ?
> [...]
> if( ! valid ) {
>
> // Instruction to repopulate the form, put the
> form in request ???
>
> errors.add( ActionErrors.GLOBAL_ERROR,
> new ActionError("errorkey", "Invalid
> data"));
> saveErrors(request, errors);
> return mapping.findForward("error"); // forward
> to the form
> }
> [...]
>
> Thank you for any kind help !
> --
> View this message in context:
>
http://www.nabble.com/Repopulate-form-in-execute%28%29-method---Struts-1-tf4611970.html#a13170657
> Sent from the Struts - User mailing list archive at
> Nabble.com.
>
>
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]