The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
February 2002

Advertisement

Advertisement

This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.

Message:

Autocomplete

Posted by Paul Walia (jinhotty) on February 22, 2002 at 4:02 PM

> Hi all,

> I would like to implement something like a listfield in ACCESS. Like when you start typing in a text field possible matches from a database select autocomplete while you type.

> Is something like that doable in java?

> thanks for your help, Peter


you could simply use a key event , that is onkey released you invoke a method to check for familiar words... use String.startWith(String) method. However to avoid System waiting for that method to be over , good idea would be to use a thread and Synchronization may be used to ensure sequencial feed back from your method.



Replies:

Sponsored Links



Google
  Web Artima.com   
Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us