Re: T5: query about onValidateForm()

2009-10-21 Thread Stephan Windmüller
Ulrich Stärk wrote: > It's working fine here using String. This works when providing an array of > strings for the model > parameter as well es when using an enum (I don't have other use cases atm). > With an enum, your > parameter can also have the respective enum type. I used it with someth

Re: T5: query about onValidateForm()

2009-10-21 Thread Ulrich Stärk
It's working fine here using String. This works when providing an array of strings for the model parameter as well es when using an enum (I don't have other use cases atm). With an enum, your parameter can also have the respective enum type. Uli Am 21.10.2009 15:09 schrieb Stephan Windmüller:

Re: T5: query about onValidateForm()

2009-10-21 Thread Stephan Windmüller
Ulrich Stärk schrieb: > That's not quite right. onValidateFromXYZ() ist called for field xyz as soon > as that field > validates. You can give it a parameter that gets populated with the field's > value. Which class do I have to use while validating a select component? Neither String nor Objec

Re: T5: query about onValidateForm()

2009-10-21 Thread Ulrich Stärk
or clearing this up. -Original Message- From: Geoff Callender [mailto:geoff.callender.jumpst...@gmail.com] Sent: 21 October 2009 13:21 To: Tapestry users Subject: Re: T5: query about onValidateForm() And you'd be well advised to get in the habit of doing all the work in onValida

RE: T5: query about onValidateForm()

2009-10-21 Thread Newham, Cameron
riginal Message- From: Geoff Callender [mailto:geoff.callender.jumpst...@gmail.com] Sent: 21 October 2009 13:21 To: Tapestry users Subject: Re: T5: query about onValidateForm() And you'd be well advised to get in the habit of doing all the work in onValidate() because errors occurrin

Re: T5: query about onValidateForm()

2009-10-21 Thread Geoff Callender
And you'd be well advised to get in the habit of doing all the work in onValidate() because errors occurring in onSuccess() won't display properly: https://issues.apache.org/jira/browse/TAPESTRY-1972 Cheers, Geoff On 21/10/2009, at 7:42 PM, Ulrich Stärk wrote: Please read the f

Re: T5: query about onValidateForm()

2009-10-21 Thread Ulrich Stärk
Please read the first paragraph of [1]. In short: submit gets fired regardless of the validation outcome, success if validation was successful, failure if not. validateForm is fired after the individual field's validate events and allows for cross-field validation. Uli [1] http://tapestry.ap

Re: T5: query about onValidateForm()

2009-10-21 Thread cordenier christophe
I prefer to use onSuccess method and handle second level validation in onValidate and onValidateFromXxx method. I use @Validate for first level validation, and sometime create my own validator when it's possible. Regards, Christophe. 2009/10/21 Newham, Cameron > Apologies if this is obvious, bu

T5: query about onValidateForm()

2009-10-21 Thread Newham, Cameron
Apologies if this is obvious, but I'm getting confused over how and where onValidateForm() should be used. I have a page with search fields in a form and also a grid for the results. Currently I have: public void onValidateForm() { if (title == null && issn == null