Searching in ComboBox/ListBox

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi there
Can anybody teel me how to make a search function like in MSDN or the other products of Microsoft
What I mean is
When we type a letter 'P', everythings that begin with 'P' will show up in the first line of the box
When we type a letter 'Put', everythings that begin with 'Put' will show up in the first line of the box

The code is welcome
Thanks

J
 
* "=?Utf-8?B?Sm9hY2hpbQ==?= said:
Can anybody teel me how to make a search function like in MSDN or the other products of Microsoft ?
What I mean is :
When we type a letter 'P', everythings that begin with 'P' will show up in the first line of the box.
When we type a letter 'Put', everythings that begin with 'Put' will show up in the first line of the box.

Sort the items in the listbox (property 'Sorted'), then use its
'FindString' method to find the item and set its 'TopIndex' property to
the item number returned by 'FindString'.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top