Re: Validation of multiple textfield in a dynamic ListView

2009-04-17 Thread Igor Vaynberg
override form.onvalidate()

-igor

On Fri, Apr 17, 2009 at 7:05 AM, Thierry Leveque tleve...@gmail.com wrote:
 Hi

 I have a validation problem that I can figure out how to do:

 I have build a dynamic table for the user to enter data into text fields.
 I am using the ListView component and some ajax behavior.
 Users can add and delete rows of the table. Everything works well, except
 for the validation.

 One of the column in the table is a port number. And guess what, port values
 must be unique in the table.

 How can I do that kind of validation?

 I was thinking of using a Form Validator, but the problem is that form
 components are added and deleted dynamically.

 Any idea?

 Thierry


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



Re: Validation of multiple textfield in a dynamic ListView

2009-04-17 Thread Thierry Leveque
Ok, that is a good start.

Now how do I access the form data within that method?
Is there any documentation on that or any example?

Thanks!

Thierry
Sent from Montreal, Quebec, Canada

On Fri, Apr 17, 2009 at 14:22, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 override form.onvalidate()

 -igor

 On Fri, Apr 17, 2009 at 7:05 AM, Thierry Leveque tleve...@gmail.com
 wrote:
  Hi
 
  I have a validation problem that I can figure out how to do:
 
  I have build a dynamic table for the user to enter data into text fields.
  I am using the ListView component and some ajax behavior.
  Users can add and delete rows of the table. Everything works well, except
  for the validation.
 
  One of the column in the table is a port number. And guess what, port
 values
  must be unique in the table.
 
  How can I do that kind of validation?
 
  I was thinking of using a Form Validator, but the problem is that form
  components are added and deleted dynamically.
 
  Any idea?
 
  Thierry
 

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




Re: Validation of multiple textfield in a dynamic ListView

2009-04-17 Thread Igor Vaynberg
however you want. you have the object graph. you can either use a
visitor to locate whatever components you want, or you can keep direct
references, or you can use a visitor to broadcast an event. completely
up to you.

-igor

On Fri, Apr 17, 2009 at 12:44 PM, Thierry Leveque tleve...@gmail.com wrote:
 Ok, that is a good start.

 Now how do I access the form data within that method?
 Is there any documentation on that or any example?

 Thanks!

 Thierry
 Sent from Montreal, Quebec, Canada

 On Fri, Apr 17, 2009 at 14:22, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 override form.onvalidate()

 -igor

 On Fri, Apr 17, 2009 at 7:05 AM, Thierry Leveque tleve...@gmail.com
 wrote:
  Hi
 
  I have a validation problem that I can figure out how to do:
 
  I have build a dynamic table for the user to enter data into text fields.
  I am using the ListView component and some ajax behavior.
  Users can add and delete rows of the table. Everything works well, except
  for the validation.
 
  One of the column in the table is a port number. And guess what, port
 values
  must be unique in the table.
 
  How can I do that kind of validation?
 
  I was thinking of using a Form Validator, but the problem is that form
  components are added and deleted dynamically.
 
  Any idea?
 
  Thierry
 

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




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