473,395 Members | 1,623 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Combobox autocomplete implementation?

VM
How can I implement the autocomplete functionality in a Windows comboBox?

Thanks.
Nov 16 '05 #1
2 10604
VM wrote:
How can I implement the autocomplete functionality in a Windows comboBox?


http://www.planet-source-code.com/vb...2165&lngWId=10

Cheers

Arne Janning
Nov 16 '05 #2
VM,

These are the steps to implement autocomplete

1. derive a class say "MyComboBox from ComboBox class
2. Add a member called mStringList which is an string array
3. For each new entry in combo, add it to string list.
4. On Keypress of comboBox search the string in the mStringlist and display
in combo box.
example
foreach(string str in mStringList)
{
if(str.StartsWith(cmbTest.Text) == true)
{
//fill autocomplete here.
cmbTest.Text = str;
break;
}
}
Shak.


"VM" <vo******@yahoo.com> wrote in message
news:uk**************@TK2MSFTNGP11.phx.gbl...
How can I implement the autocomplete functionality in a Windows comboBox?

Thanks.

Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: VM | last post by:
How can I implement the autocomplete functionality in a Windows comboBox? Thanks.
3
by: RajW | last post by:
Is it possible to have an auto complete ComboBox in ASP.NET? I would like to create a ComboBox that functions similarly to the way that IE will try to autocomplete a URL as you type it in. ...
19
by: Bernie Yaeger | last post by:
Everyone misses the point on this - what we need is a combobox autocomplete that is a dropdownlist only. When in dropdown mode, you can enter text - making that autocomplete is trivial. But when...
2
by: Becker | last post by:
I have a need for a simple combobox on a form in one of my programs that represents city, state. I want to have it autocomplete as the user types. I have a table with these values (about 50k of...
2
by: Kalvin | last post by:
I found some code in Google, don't remember where, for an AutoComplete combobox. Everything is great with it except for one thing. If I use the mouse to drop the list down, then start typing to...
1
by: David Tilman | last post by:
I'm working with C# in Visual Studio 2005. I have a combobox with AutoCompleteSource = ListItems and DropDownStyle = DropDown. I want users to be able to type in the combobox and the control to...
4
by: =?Utf-8?B?UmljaA==?= | last post by:
Greetings, I have to load 30,000 unique names into a combox. Filling a dataTable takes only a few milliseconds. But populating the combobox and displaying the list takes several seconds - way...
6
by: ezyeric13 | last post by:
I have a series of ComboBox's Bound to a DataGridView and I turned the AutoComplete on for them so they list all the items in a certain collumn of the DataGridView. The problem is that when you...
3
by: =?Utf-8?B?bWVtZWFk?= | last post by:
I have a combobox displaying the full name of a customer (e.g. John Smith) and would like to go to the LAST name whenever a user presses a key while on this combobox. I have looked at the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.