Hi, As u told u need it urgently i thought of putting some light into it. First thing is dont use NumberValidator in ur case. Instead use StringValidator; Ur code can be re-written as follows.
<mx:StringValidator maxLength="6" minLength="6" id="eventTypeTxt" required="true" source="{employeeid}" property="text" tooLongError="Your id is more than 6 numbers" tooShortError="Your Id values should not exceed or trucate 6" /> This will surely work. Additionally in ur TextInput use maxChars="6" e.g: <mx:TextInput x="55" y="144" id="employeeid" restrict="0-9" maxChars="6" /> By doing this u r preventing user from entering more than 6 characters. depending upon ur requirement u choose which one u want to use. hope this will be of little use to u:) regards, http://flexphpworld.wordpress.com/ On Mar 12, 4:01 pm, Fehmina Kanuga <whitepearl.fehm...@gmail.com> wrote: > HI all, > I have userId field... that filed should contain only number and its should > be neither less than 6 and not more than 6 only 6 number digit should be > there.. > how do i achive it > > <mx:NumberValidator id="eventTypeTxt" > > required="true" source="{employeeid}" > > property="text" maxValue="6" exceedsMaxError="Your id is more than 6 numbers" > minValue="6" lowerThanMinError="Your Id values should not exceed or trucate > 6"/> > > at present i m using it... but its not working -- You received this message because you are subscribed to the Google Groups "Flex India Community" group. To post to this group, send email to flex_in...@googlegroups.com. To unsubscribe from this group, send email to flex_india+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/flex_india?hl=en.