You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by sakthi vel <ve...@gmail.com> on 2010/01/07 17:30:47 UTC

TextField & Class Type Validation

Hello,

I have a text field and added the class type as Date, to validate the date
entered.

TextField txtDate = new TextField("txtDate", new Model(), Date.class);


I have two button in the same screen one for the Save for another for Reset.
When i enter invalid date and press the save button, valid error message is
shown. But when i press the reset button then also it validates and shows
the errro message.

How to avoid this and kindly explain the factor.

Re: TextField & Class Type Validation

Posted by Fatih Mehmet UCAR <fm...@gmail.com>.
button.setDefaultFormProcessing(boolean b)

http://wicket.sourceforge.net/apidocs/wicket/markup/html/form/Button.html#setDefaultFormProcessing%28boolean%29


----- Original Message ----- 
From: "sakthi vel" <ve...@gmail.com>
To: <us...@wicket.apache.org>
Sent: Thursday, January 07, 2010 4:30 PM
Subject: TextField & Class Type Validation


> Hello,
>
> I have a text field and added the class type as Date, to validate the date
> entered.
>
> TextField txtDate = new TextField("txtDate", new Model(), Date.class);
>
>
> I have two button in the same screen one for the Save for another for 
> Reset.
> When i enter invalid date and press the save button, valid error message 
> is
> shown. But when i press the reset button then also it validates and shows
> the errro message.
>
> How to avoid this and kindly explain the factor.
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org