First off, thanks for the new "Contains" feature. It works great with one possible exception.
One of my WinCombo's datasource is a list of Statuses, two of which have DisplayValues of "Issued" and "Re-Issued". The AutoCompleteMode is set to "Suggest" and AutoSuggestFilterMode is set to "Contains" for this WinCombo. The auto suggest in combination w/ contains works great when an end user is making their selection but I have hit an issue with this. I programatically set the value of this WinCombo when another form event fires and even though I am setting the valuemember for "Issued" , the WinCombo auto suggests both "Issued" and "Re-Issued."
Upon further investigation, the value portion is set properly but even though it has a valid value, it suggests more options (based off of the new "Contains" property). What bothers me is that this happens even if the control doesn't have focus. I know how to determine if a WinCombo is dropped down and also close it but I certainly don't want to have to put this type of extra processing throughout my application.
So my question is this, is this a "Bug/Issue" or is there a property that I can also enable/disable on the WinCombo to correctly take advantage of the "Contains" AutoSuggestFilterMode?
-Ian
Hi Ian,
I'm afraid I am not following you. You are saying that you are setting the Value property of the combo in code and the control does not have focus, but you are seeing suggestions pop up? If that's the case, then it's clearly a bug.
Mike and Dan,
I have a similar issue. I have a combobox in a grid cell. When autosuggest.append is turned on this is what happens.
If the combo is populated with names like Brad Hirsch and James Hirsch the combo allows me to select James Hirsch but Brad Hirsch is saved to the database. From what I can tell the row_selected method fires twice. The first time through is selects the correct row, the second time through it finds the first match and selects it.
I am running the 2009 Vol2 winform controls.
ThanksKevin
Hi Kevin,
Are you saving the actual strings to the data? Or are you using the dropdown to provide a translation from ID to display text? My guess is that your "Brad Hirsh" and "James "Hirsh" simply have the same ID number. Otherwise, I can't see how the grid could possibly be displaying the correct text while saving the wrong text.
Also.... are you sure that this only happens when you using AutoSuggest? I can't see why that would matter.
Mike,
I am saving the ID and I am searching the last name column. It makes no difference wether autosuggest is on or off.
It is firing the rowchanged event twice on the combobox. If you had time for a web meeting I would live to find out if you see something I don't. I have no clue why it fires twice but the combobox match the second time through is first occurance of the last name not the ID.
Should I be using the valuechanged instead of rowselected method?