Re: AutoComplete ComboBox Search on Substring for KeyPress
- From: Lloyd Sheen <a@xxx>
- Date: Wed, 13 Aug 2008 21:19:54 -0400
memead wrote:
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 AutoCompleteMode and AutoCompleteSource properties of the combobox, but they only key off of the FIRST name (e.g. pressing "B" will select "Bob Smith", not "Sam Barnes"). Even FindString and FindStringExact only appear to key off of the prefix. This combobox, cboCustomer, has a .DataSource set to a DataView (dv) which contains two fields, the customer's name (e.g. "John Smith") and their customer number (e.g. 12345). The .ValueMember of this combobox is dv.CustomerNumber and the .DisplayMember is set to dv.FullName. How can I set the AutoCompleteSource (?) to be a substring (Last Name) of the .DisplayMember (Full Name)? I looked at Ken Tucker's response in "Typing in a ComboBox" (04/12/2006) and it look interesting, but I do not know if this would help me. Any help is appreciated.
Thank you.
I have an implementation that uses a text box and a hidden (until typing) listbox. It will present names on a "contains" basis. I am not near the box the code is on but will post it tommorow.
LS
.
- Follow-Ups:
- Re: AutoComplete ComboBox Search on Substring for KeyPress
- From: Lloyd Sheen
- Re: AutoComplete ComboBox Search on Substring for KeyPress
- References:
- Prev by Date: RE: AutoComplete ComboBox Search on Substring for KeyPress
- Next by Date: Re: Missing DAO licence on target PC
- Previous by thread: RE: AutoComplete ComboBox Search on Substring for KeyPress
- Next by thread: Re: AutoComplete ComboBox Search on Substring for KeyPress
- Index(es):
Relevant Pages
|