Joshi, Looks like a typo problem to me, one is defined as MyDynaForm and the other is MySDynaForm.
Cheers Mark -----Original Message----- From: Joshi, Sachin (MED) [mailto:[EMAIL PROTECTED] Sent: Monday, 22 September 2003 2:44 p.m. To: [EMAIL PROTECTED] Subject: Validator framework with Struts problem I am trying to use Jakarta commons validator framework with Struts in my application but its not working for me can someone tell me how can it be done, I am trying to do validation for a required atttribute Here is my validation-rules.xml <form-validation> <global> <validator name="required" classname="org.apache.struts.util.StrutsValidator" method="validateRequired" methodparams="java.lang.Object, org.apache.commons.validator.ValidatorAction, org.apache.commons.validator.Field, org.apache.struts.action.ActionErrors, javax.servlet.http.HttpServletRequest" msg="errors.required"/> <validator name="minlength" classname="org.apache.struts.util.StrutsValidator" method="validateMinLength" methodparams="java.lang.Object, org.apache.commons.validator.ValidatorAction, org.apache.commons.validator.Field, org.apache.struts.action.ActionErrors, javax.servlet.http.HttpServletRequest" depends="required" msg="errors.minlength"/> </global> </form-validation> here is my validator.xml <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <form-validation> <global> <constant> <constant-name>datePatternStrict</constant-name> <constant-value>MM/DD/yyyy</constant-value> </constant> <constant> <constant-name>timePatternStrict</constant-name> <constant-value>HH:MN</constant-value> </constant> </global> <formset> <form name="MyDynaForm"> <field property="field" depends="required"> <msg name="required" key="errors.required"/> <arg0 key="myfeature.field"/> </field> </form> </formset> </form-validation> Here is my DynaForm defication in struts-config.xml <form-bean name="MySDynaForm" type="org.apache.struts.validator.DynaValidatorActionForm"> <form-property name="field" type="java.lang.String" /> </form-bean> Please let me know if there are some problems here Thanks & Regards, Sachin The information contained in this e-mail (and any accompanying attachments) is confidential and may be legally privileged. The information is intended only for the recipient(s) named in this message. Any reading, copying, distribution or any other use of the information by the intended recipient other than the addressee/s is prohibited. If you have received this message in error, please delete the message and any attachments and notify HealthPAC immediately by email to [EMAIL PROTECTED]
