Java TextFields, keyTyped Vs insertUpdate Events

It's been a while since I last posted, I have been spending a lot of my spare time on a java application where I came across a problem with the keyTyped() Event.

The task I was trying to achieve was to reproduce a similar feature to google suggest which was fairly straight forward simply using a Collection to store all my values and the Iterator to loop through each value checking against my search string which was retrieved using the getText() method and then matched against each value using the startsWith() method.

Add new comment

The content of this field is kept private and will not be shown publicly.

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.