Hi David,

Thanks for the info but still not made progress and wonder if you 
can help or point me in the right direction for implementation 
guidance. 

I tried downloading latest nightly build of commons-validator 
(commons-validator-20030826.zip)as you suggested  and deployed it 
into my application to the WEB-INF/lib directory but still got the 
same result as before (validation occurs but no pop up error 
messages appearing)

Am I using the correct syntax in the strut-config.xml and 
validation.xml and my jsp or do I need to change it? Are there any 
online notes as to how to correctly use the fixed commons-validator 
for validating property String arrays ?

Thanks and regards

Suhel

--- In [EMAIL PROTECTED], David Graham <[EMAIL PROTECTED]> 
wrote:
> Commons Validator was recently modified to allow the required 
validation
> in Struts to run on String[] or Collection objects.  You can 
download the
> latest Validator nightly build to try it out.
> 
> David
> 
> --- java-dude <[EMAIL PROTECTED]> wrote:
> > Hi,
> > 
> > I am having problems using  Validator framework to perform 
client 
> > side validation on a String array property declared in a 
> > DynaValidatorForm.
> > 
> > The results are that the validation does seem to work in a 
fashion 
> > such that the user is not taken to the next page and is kept on 
> > current jsp while data entered is invalid BUT no pop up alert 
error 
> > messages are being diplayed. (For other forms in the application 
> > where I am validating single properties the validation and pop 
up 
> > error messages are working fine.)
> > 
> > Has anybody solved/encountered this problem ?
> > 
> > I have provided the relevant snippets from my current 
configuration 
> > to illustrate my implementation :-
> > 
> > struts-config.xml
> > =================
> > .
> > .
> > .
> > <form-bean 
> >      name="enterReadingForm" 
> >      type="org.apache.struts.validator.DynaValidatorForm">
> >      <form-property name="theReading" type="java.lang.String[]"/>
> > </form-bean>
> > .
> > .
> > .
> > 
> > validation.xml
> > ==============
> > .
> > .
> > .
> > <form name="enterReadingForm">
> >   <field property="theReading" indexedListProperty="theReading"
> >   depends="required,minlength,maxlength,mask">
> >     <arg0 key="prompt.theReading"/>
> >     <arg1   key="${var:minlength}" name="minlength"
> >      resource="false"/>
> >     <arg2   key="${var:maxlength}" name="maxlength"
> >      resource="false"/>
> >     <var>
> >         <var-name>minlength</var-name>
> >         <var-value>1</var-value>
> >     </var>
> >     <var>
> >         <var-name>maxlength</var-name>
> >         <var-value>6</var-value>
> >     </var>
> >     <var>
> >         <var-name>mask</var-name>
> >         <var-value>^[0-9]*$</var-value>
> >     </var>
> >   </field>
> > </form>
> > .
> > .
> > .
> > 
> > ApplicationResources.properties
> > ===============================
> > .
> > .
> > .
> > prompt.theReading=The Reading
> > .
> > .
> > .
> > 
> > enterReading.jsp
> > ================
> > .
> > .
> > .
> > <nested:iterate id="registerDetails" name="readingDetails" 
> > scope="page" property="register">
> >     <nested:text name="registerDetails"
> >      property="theReading" size="6" maxlength="6"/>
> > </nested:iterate>
> > .
> > .
> > .
> > 
> > 
> > 
> > -----------------------------------------------------------------
----
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software
> http://sitebuilder.yahoo.com
> 
> -------------------------------------------------------------------
--
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


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

Reply via email to