what happens if you set the field type to String? If that fails validation for an integer when you enter non-integer text, it will prove that the validator is being invoked and you can go on from there.
Adam
On 10/01/2003 11:13 AM Frederic Dernbach wrote:
Hello,
I cannot get the DynaValidatorForm to work. It does not do anything.
In struts-config.xml, I declared the form bean as : <form-bean name="strategyListForm" type="org.apache.struts.validator.DynaValidatorForm"> <form-property name="itemCount" type="java.lang.Integer" initial="5"/> </form-bean>
In struts-config.xml, I added the action : <action path="/StrategyList" type="com.rubis.web.system.StrategyListAction" scope="request" validate="true" name="strategyListForm" attribute="strategyListForm" parameter="reqCode"> <forward name="success" path="/strategy/strategyList.jsp" /> </action>
In struts-config.wml, I added the required plug-in : <plug-in className="org.apache.struts.validator.ValidatorPlugIn"> <set-property property="pathnames" value="/WEB-INF/validator-rules.xml,/WEB-INF/validation.xml"/> </plug-in> JBoss tells me it loaded both validation-rules.xml and validation.xml files.
In validation.xml I added the following : <form-validation> <formset> <form name="strategyListForm"> <field property="itemCount" depends="required, integer"> <arg0 key="rubis.common.fieldname.itemcount"/> </field> </form>
</formset> </form-validation>
But no error is triggered if I input let's say a string for my itemCOunt field. It looks like to validation happens.
Any idea ??
Fred
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- struts 1.1 + tomcat 5.0.12 + java 1.4.2 Linux 2.4.20 RH9
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

