The reset method and reset buttons are two separate things.

If you are using a session-scoped ActionForm with a boolean property
that is represented by a checkbox, you can use reset to set the
boolean property to false prior to autopopulation. Otherwise, given
the way radio controls work, there is no way to uncheck a
session-scoped boolean.

The reset button is the corollary to the HTML reset button. It is
included mainly for completeness, and it is not related to the reset
method.

HTH, Ted.

On 4/19/06, Zheng Wen Zhe <[EMAIL PROTECTED]> wrote:
> Hi ye,
> I have an action form with submit & reset buttons.
> In the form been class, I do declare the reset method to clear up all the
> text fields.
>
> Here is the situation, after filling in some data into some text field, I
> select the Reset button. The reset method is called, but those text fields
> doesn't clear up.
> Could anyone tell me why??
>
> Cheers,
>
> Jason
> ************The reset method********************
>
> public void reset(ActionMapping mapping,
>                                    HttpServletRequest request){
>                 firstName = null;
>                 lastName = null;
>                 userName = null;
>                 password = null;
>                 passwordCheck = null;
>                 email = null;
>                 phone = null;
>                 fax = null;
>                 registered = false;
>                 System.out.println("Call reset method in Form...");
>         }
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
HTH, Ted.
** http://www.husted.com/ted/blog/

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

Reply via email to