0 Replies Latest reply on Oct 3, 2009 10:12 AM by flashharry!

    Supporting maxChars on editable ComboBox, string validator null out input once max is reached

    flashharry! Level 1

      I have a ComboBox in a form set to editable, so it acts like a text input but as drop down values as well.

      The data here is required and I want to limit the number of characters that can be entered, normally under a TextInput control you would just set the maxChars.
      I have created a string validator, required is based on seletedLabel so that working as I would expect.
      I set a maximum character limit in the validator which does not limit the text but prevents validation if the count is over, so far so good.
      Now the issue, imagine you set this to 10 characters  maximum, type the 11th character the validator correctly invalidates the control and the standard message pops up and prevent form submission.
      But if the user is still typing as soon as you enter one character over the limit in this example the 12th character the input nulls out to empty string.
      I want to limit the the number of characters that can be typed or the validator to not null out, giving the user a chance to back space instead of clearing the input.
      Any ideas?
      TIA
      flash.