aspose file tools
The moose likes Swing / AWT / SWT and the fly likes Displaying possible (user intended) Strings as suggestions in a JList Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » Swing / AWT / SWT
Reply Bookmark "Displaying possible (user intended) Strings as suggestions in a JList" Watch "Displaying possible (user intended) Strings as suggestions in a JList" New topic
Author

Displaying possible (user intended) Strings as suggestions in a JList

Mansoor Akhtar
Greenhorn

Joined: Jul 11, 2010
Posts: 12
I need to display (user intended) Strings in some sort of a JList (or something ) when user types in a JTextField as possible suggestions. We do witness the same behavior in many email clients like Gmail when we start typing an email address. Can anyone please guide me how can I achieve this in Java applications. I want it to be like all possible options (based on some soundex algorithm) so that the user could choose on of the strings.
Thanks in advance.
Michael Dunn
Ranch Hand

Joined: Jun 09, 2003
Posts: 4632
there are many examples here and google, search keywords

autocomplete JTextField (and/or JComboBox)
Mansoor Akhtar
Greenhorn

Joined: Jul 11, 2010
Posts: 12
Thanks a lot.
I have found a good example at: http://www.codeguru.com/forum/showthread.php?t=477880
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 32830
    
    4
And welcome to JavaRanch
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Displaying possible (user intended) Strings as suggestions in a JList
 
Similar Threads
JList maximum size?
Set focus on selected item in scrollable JList
Vectors and Collections and Hashtables - which to choose
JComboBox and keypress
JList + Vector