For guiding user through  alert to enter proper value use invalid
event of NumberValidator  as shown in code below.
=====================================================================================
<?xml version="1.0" encoding="utf-8"?>

<mx:Application
        xmlns:mx="http://www.adobe.com/2006/mxml";
        layout="vertical"

       >

    <mx:Script>
        <![CDATA[
        import mx.controls.Alert;

        ]]>
    </mx:Script>


<mx:NumberValidator source="{Overallrfp}" property="text"
invalid="Alert.show('Please Enter Integer');"
integerError="Enter Integer value"  domain="int"  required="false" />

<mx:Label text="Overall RFP value in $: " width="145" height="18"
x="67"
y="56" fontSize="11"/>

<mx:TextInput x="225" y="58" height="18" width="120" id="Overallrfp"/
>

</mx:Application>
=================================================================================================
For Exception, it will be great of help if you can mention it. It can
be NAN issue, hard to guess without seeing exception message.
=================================================================================================
On Mar 9, 11:49 pm, FlexiSush <sushant...@gmail.com> wrote:
> Hi, can u plz elaborate what kind of exception u r getting??
>
> Regards,http://flexphpworld.wordpress.com/
>
> On Mar 9, 2:34 pm, Fehmina Kanuga <whitepearl.fehm...@gmail.com>
> wrote:
>
> > hi all,
> > when i m not entering any data and hittting the remote object.... on flex
> > side i m getting exception...
> > however if i m entering digits its working fine...
>
> > On Tue, Mar 9, 2010 at 2:24 PM, Fehmina Kanuga <whitepearl.fehm...@gmail.com
>
> > > wrote:
> > > HI all,
> > > thank you very much..
> > > that worked for me..
>
> > > But one more query...cant we have any alert...to guide user that we need
> > > only integer values...
>
> > >   On Mon, Mar 8, 2010 at 5:54 PM, FlexiSush <sushant...@gmail.com> wrote:
>
> > >> hey no need to use any validator. just use restrict property of
> > >> TextInput and set it as restrict="0-9"  Hope it works
>
> > >> Regards,
> > >>http://flexphpworld.wordpress.com/
>
> > >> On Mar 8, 3:26 pm, Fehmina Kanuga <whitepearl.fehm...@gmail.com>
> > >> wrote:
> > >>  > HI,
> > >> > i have a scenario.
>
> > >> > i have one field  say user id , This field is not mandatory.
> > >> > However if at all user enters it.. it should be only numeric fields..
>
> > >> > how do i perform that validaton..?
> > >> > i tried using
>
> > >> > <mx:Script>
>
> > >> >      import mx.controls.Alert;
>
> > >> >  </mx:Script>
>
> > >> > <mx:NumberValidator source="{Overallrfp}" property="text"
> > >> > integerError="Enter Integer value"  domain="int"  required="false" />
>
> > >> > <mx:Label text="Overall RFP value in $: " width="145" height="18" 
> > >> > x="67"
> > >> > y="56" fontSize="11"/>
>
> > >> > <mx:TextInput x="225" y="58" height="18" width="120" id="Overallrfp"/>
>
> > >> > but  its not working...
>
> > >> > if i m not entering any values then its thworing exception
>
> > >>  --
> > >> 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<flex_india%2bunsubscr...@googlegroups.com>
> > >> .
> > >> For more options, visit this group at
> > >>http://groups.google.com/group/flex_india?hl=en.

-- 
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.

Reply via email to