Re: How work to DynaValidatorForm and java.sql.Date
Hi Pedro, I'd like know how i work to java.sql.Date, in my form bean I'm know work to fields String , but in Specification of DynaValidator show that DynaValidator support java.sql.date, but I have the problem show in e-mail number one, Somebody help me Thanks, On Thu, 07 Oct 2004 21:18:46 +0100, Pedro Salgado [EMAIL PROTECTED] wrote: On 7/10/04 1:00 am, Gabriel França Campolina [EMAIL PROTECTED] wrote: Hi Folks, I have the problem when i submit a field text that was mapping to java.sql.date in format dd/MM/, I received null value, what´s my problem?? only this value I don't received the other fields(String) i receved correct. You should always use java.lang.String (or String[]) on your form-bean properties. The validation part should be implemented on the form validate() method or on the validator or on the struts action itself (-). Pedro - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Gabriel França Campolina Tel: 9202-8320 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How work to DynaValidatorForm and java.sql.Date
Hi Gabriel, As many of struts people here i think that the less error prone approach is using only String properties in your custom ActionForm classes. So, it will be quite easy to handle invalid data and whatelse you need to. After validating your form (calling your validate() method from your Action is the best way when using straight ActionForm instances i think), you can convert your date from String to java.sql.Date using a converter class. Cheers, Daniel Silva. --- Gabriel França Campolina [EMAIL PROTECTED] wrote: Hi Pedro, I'd like know how i work to java.sql.Date, in my form bean I'm know work to fields String , but in Specification of DynaValidator show that DynaValidator support java.sql.date, but I have the problem show in e-mail number one, Somebody help me Thanks, On Thu, 07 Oct 2004 21:18:46 +0100, Pedro Salgado [EMAIL PROTECTED] wrote: On 7/10/04 1:00 am, Gabriel França Campolina [EMAIL PROTECTED] wrote: Hi Folks, I have the problem when i submit a field text that was mapping to java.sql.date in format dd/MM/, I received null value, what´s my problem?? only this value I don't received the other fields(String) i receved correct. You should always use java.lang.String (or String[]) on your form-bean properties. The validation part should be implemented on the form validate() method or on the validator or on the struts action itself (-). Pedro - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Gabriel França Campolina Tel: 9202-8320 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ___ Do you Yahoo!? Declare Yourself - Register online to vote today! http://vote.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How work to DynaValidatorForm and java.sql.Date
On 7/10/04 1:00 am, Gabriel França Campolina [EMAIL PROTECTED] wrote: Hi Folks, I have the problem when i submit a field text that was mapping to java.sql.date in format dd/MM/, I received null value, what´s my problem?? only this value I don't received the other fields(String) i receved correct. You should always use java.lang.String (or String[]) on your form-bean properties. The validation part should be implemented on the form validate() method or on the validator or on the struts action itself (-). Pedro - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How work to DynaValidatorForm and java.sql.Date
Hi Folks, I have the problem when i submit a field text that was mapping to java.sql.date in format dd/MM/, I received null value, what´s my problem?? only this value I don't received the other fields(String) i receved correct. Sorry my english I'm brasiliam Thanks, -- Gabriel França Campolina - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]