You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Ashish Kulkarni <ku...@yahoo.com> on 2003/03/04 17:13:33 UTC

struts validation question

Hi,
I have 3 questiona about handling validation in struts
1.1b3, using dyna form and using validation.xml

Q1, Suppose i have to validate date for 3 different
format depending upon a value set in sessio, so if the
value of fomrat is '1' date format is  dd/MM/yy, if
'2' date format is MM/dd/yy and  '3' date format is
yy/MM/dd
Also how to use mask for field entry

Q2, Validating numeric field, for '.' and ',' for
decimal values, like in US "." is used for decimal
while  in france "," is used for decimal value is
double. so how do i validate depending upon local, or
using a value set in session, like if the valus is '1'
then the valid decimal is "." and if the vaus is "2"
the valid decimal is ","

Q3, Is there a way to validate number of digits before
decimal and after decimal, 
like valid value is 123.23 but not 12.323

Any code or defination in validation.xml will really
help, 
Do i have to write custom validtor for above
requirements or is there a way to do it in struts

Ashish







__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org