there is a simple way to do that without the feedback panel. add a label with the error message and override its isvisible to poll the form component

ie

add(new Label("error", "phonenumber invalid") {
                  isvisible() { return !textfield.isValid(); });

-Igor


On 12/10/05, Cameron Taggart < [EMAIL PROTECTED]> wrote:
I would like to have only one validation error message show up in the
feedback panel when an invalid mobile phone number is entered.
Currently, it is possible for more than one validation error to show
up.  To get an idea of the validators and what they are validating,
here are my properties for the form:

form.mobileNumber.RequiredValidator=Please enter a valid ten digit phone number.
form.mobileNumber.LengthValidator=Please enter a valid ten digit phone
number. (incorrect length)
form.mobileNumber.PatternValidator=Please enter a valid ten digit
phone number. (only digits)

I would like to display only "Please enter a valid ten digit phone
number." once to the user.  Is ther a good approach to this?  I'm
currently looking at ComponentFeedbackMessageFilter and looking into
see what Form.validate() does, but I'm not sure I'm on the right
track.

Cameron


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_idv37&alloc_id865&opclick
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to