Using struts validation I am validating date entered.

        <field property="birthDate"
             depends="date">
             <arg0 key="userRegistration.birthDate"/>
             <var>
                 <var-name>datePatternStrict</var-name>
                 <var-value>MM-dd-yyyy</var-value>
             </var>
      </field>

On entering an invalid date Validation error message says "Entered Date of
Birh is invalid".

But what i would like the message to read is "Entered Date of Birth
[02/21/2005] is invalid".

How do i configure date-validation such that it picks up the value of the
Date field and not just the field name from the applicaiont.properties.

One way is to override validate method in the Form and manifacture the above
message, but it would be good if I can get the work done declaratively from
validation.xml

Thanks for any help.
Prashant


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to