not sure.. but check if this helps http://www.adobe.com/cfusion/exchange/index.cfm?event=extensionDetail&extid=1049969
you might need to modify the original code.. ~Peeyush http://www.mds.asia On Tue, Mar 2, 2010 at 8:30 PM, sasuke <[email protected]> wrote: > > > > Hi all. > > How would I achieve the task of restricting user input based on the current > contents of the TextInput? I am aware of the restrictChars property but > that > doesn't help since it applies a blanket rule as to which characters are > allowed/not allowed. > > An example here would be: allow the user to input a number with no more > than > a precision of 2. In this case, as soon as the user enters 12.34 any more > keystrokes in the TextInput should become no-ops. > > I did try adding event listeners to the KeyboardEvent.UP_KEY and > KeyboardEvent.DOWN_KEY but it seems that you can't stop the propagation or > prevent the default of keyboard events. > > Any suggestions here would be very much appreciated. TIA, > sasuke > -- > View this message in context: > http://old.nabble.com/Restrict-user-input-in-TextInput-tp27756858p27756858.html > Sent from the FlexCoders mailing list archive at Nabble.com. > > >

