Click here to Skip to main content
15,886,258 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
Hello guys and girls!
Im trying to make a kind of menu with a search function

Example:
We have those 5 topics:
Apple
Strawberry
Orange
Pear
Mango
Then at the top of the list there needs to be a kind of search box. When i type example "Stra" then i will be only able to see Strawberry on my list.

I made a Listbox with a search function, but that was not really what i was looking for. Hope you understand what i mean otherweise tell me :-)!
Posted
Updated 18-Feb-15 6:31am
v3
Comments
John C Rayan 18-Feb-15 10:42am    
Are you trying to do AutoComplete/AutoSuggest? If yes then use JQuery
Kuthuparakkal 18-Feb-15 10:43am    
lOOK AT THIS: http://stackoverflow.com/questions/12068154/on-the-fly-search-algorithm-in-listbox
Member 11427391 18-Feb-15 11:13am    
As i wrote, the Listbox doesn't fit what i tried to make. Since i already made something similar. But thanks!
Ravi Bhavnani 18-Feb-15 10:50am    
What platform? Web? Desktop (WinForms/WPF)? Silverlight?

/ravi
Member 11427391 18-Feb-15 11:54am    
Win application

1 solution

You may want to use a ComboBox with autcomplete.  See this[^] MSDN reference.

/ravi
 
Share this answer
 
Comments
Member 11427391 18-Feb-15 12:06pm    
Yea, it's something near that!
It would just be lovely if it wasn't a dropdown menu, but a list with the words!
Ravi Bhavnani 18-Feb-15 12:09pm    
A ComboBox has 3 diaplay modes - one of them resembles an always open list. Maybe that would suit your needs better?

/ravi
Member 11427391 18-Feb-15 12:14pm    
Thanks alot!! First time working with Comboboxes. Sorry for not readin through the properties correctly, but that was exactly what i was looking for!
Sergey Alexandrovich Kryukov 18-Feb-15 12:15pm    
Ravi, it would be good it the inquirer clearly indicated the use of System.Windows.Forms. I think we should wait for clarification. If you look thoroughly, you will see that the inquirer never answered your question.
—SA
Ravi Bhavnani 18-Feb-15 12:32pm    
You're right, SA. I tagged the question appropriately to help future readers.

/ravi

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900