• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

Error while using Validation Framework

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I m using struts 1.1 and while using validation framework i m getting following error.
Error:
[8/26/09 17:09:47:391 IST] 00000041 ComposableReq I org.apache.struts.chain.ComposableRequestProcessor init Initializing composable request processor for module prefix ''
[8/26/09 17:09:47:469 IST] 00000041 ValidatorForm E org.apache.struts.validator.ValidatorForm validate No such validation method: org.apache.struts.validator.FieldChecks.validateRequired(java.lang.Object, org.apache.commons.validator.ValidatorAction, org.apache.commons.validator.Field, org.apache.struts.action.ActionErrors, javax.servlet.http.HttpServletRequest)
org.apache.commons.validator.ValidatorException: No such validation method: org.apache.struts.validator.FieldChecks.validateRequired(java.lang.Object, org.apache.commons.validator.ValidatorAction, org.apache.commons.validator.Field, org.apache.struts.action.ActionErrors, javax.servlet.http.HttpServletRequest)



Validaion.xml:


<form-validation>
<formset>
<form name="registerForm">
<field property="uname" depends="required">
</field>
<field property="lname" depends="required">
</field>
<field property="age" depends="intRange">
<arg0 key="registration.lookup.field3"/>
<arg1 key="${var:min}" name="min" resource="false" />
<arg2 key="${var:max}" name="max" resource="false"/>
<var>
<var-name>min</var-name>
<var-value>10</var-value>
</var>
<var>
<var-name>max</var-name>
<var-value>20</var-value>
</var>
</field>
</form>
</formset>
</form-validation>

And Validaion-rules.xml:

<form-validation>

<global>
<validator name="required"
classname="org.apache.struts.validator.FieldChecks"
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">
</global>

</form-validation>
 
reply
    Bookmark Topic Watch Topic
  • New Topic