HOw do I use requiredif, I tried following the example, but it makes no sense to me? I know validwhen is knew but the application i'm developing on still uses struts 1.03, basically, I have field (selection box) , that when a paticular selection is chosen another field text box must filled out ... meaning it becomes mandatory.
Here is my validation.xml
<form name="FAULTREASON"
bundle="FrameworkResources">
<field property="FAULTREASON" depends="requiredif">
<arg0 key="FAULTREASON" resource="false"/>
<var>
<var-name>field[0]</var-name>
<var-value>provstatusid<var-value>
</var>
<var>
<var-name>fieldTest[0]</var-name>
<var-value>EQUAL</var-value>
</var>
<var>
<var-name>fieldValue[0]</var-name>
<var-value>10</var-value>
</var>
</field>
</form>
FAULTREASON is the text box, and provisionstatusid is a selection box , I basically want when the provisionstatusid is set to 10 (value) not the option text, then the faultreason should be set.
Also, how does the field, fieldtest, fieldvalue stuff work, and mean, as I was just following the example given on the struts site.
Thanks
Here is my validation.xml
<form name="FAULTREASON"
bundle="FrameworkResources">
<field property="FAULTREASON" depends="requiredif">
<arg0 key="FAULTREASON" resource="false"/>
<var>
<var-name>field[0]</var-name>
<var-value>provstatusid<var-value>
</var>
<var>
<var-name>fieldTest[0]</var-name>
<var-value>EQUAL</var-value>
</var>
<var>
<var-name>fieldValue[0]</var-name>
<var-value>10</var-value>
</var>
</field>
</form>
FAULTREASON is the text box, and provisionstatusid is a selection box , I basically want when the provisionstatusid is set to 10 (value) not the option text, then the faultreason should be set.
Also, how does the field, fieldtest, fieldvalue stuff work, and mean, as I was just following the example given on the struts site.
Thanks