"Mike Dewhirst" <[EMAIL PROTECTED]>



> How is it possible to validate input in struts for formatting?
> 
> What I mean is, is it possible to check when a string is entered into an
> input field that populates an int? It seems that the Controller populates
> the int with a 0, which makes it difficult to detect if this was an invalid
> input, or a "real" 0.
> 
> Would we need to extend the framework if we want to be able to detect this?
> 
> Thanks for any advice!!

You can either use String (in this way you can accept inputs like "2.001"),
or you can use Integer. It will be null, if no correct integer is has been 
entered.

--
gR

Reply via email to