1 Reply Latest reply on Jan 5, 2008 1:38 PM by VarioPegged

    TextInput Restrict

      How can i specify <space> in TextInput Restrict ?.
        • 1. Re: TextInput Restrict
          VarioPegged Level 2
          Try setting the string to a bindable variable and then bind the restrict property of the text input to it:
          private var restrictString:String = "\\<space\\>"
          <mx:TextInput restrict="{restrictString}" />

          Note that folks will still be able to enter any character within that string in any order. If you want to restrict the string specifically to the complete "<space>" or as they type "< - s- p- a- " in the proper order, you'd have to do a custom validation as they type.