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
I figured it out.... It only happens when the mode of the ultracombo is set to suggest or suggestappend.
If the mode is set in the combobox properties and you try to override it in the initialize_layout method it will not override what you set in the GUI properties.
The ultracombo works as expected and only fires once if you set the mode to append or default and use ToggleDropdown to open the ultracombobo in in the keypress method.
Example:'Since I have multiple comboboxes on the same page I have to get the correct combo.
Dim
Combo As Infragistics.Win.UltraWinGrid.UltraCombo = senderSelectedCombo = Combo'To speed up the form load I do not populate the combo until the user starts typing.
PopulateGolfers(SelectedCombo)'If the combo is not dropped down yet then lets open it so we can see the matches.
If Not Combo.IsDroppedDown Then Combo.ToggleDropdown()End If' Here I check to see if they pressed Enter. This means they used the arrow keys to navigate 'down the list and selected a row so I close the comboboxIf e.KeyChar = Microsoft.VisualBasic.ChrW(Keys.Return) Then If Combo.IsDroppedDown Then Combo.ToggleDropdown()End If
End If
One note, Toggledropdown will not open the ultracombo if it is embeded in a grid, I had to send an {f4} key in the BeforeEnterEditMode method in the grid that contains the combo. Once the combo is dropped down you can start typing or arrow down to your selection. I should say that this approach may not work everywhere.
SendKeys.Send(
"{F4}")
I suspect this has something to do with the fact that you have two items on the list with the same first and last name. And your auto-suggest is somehow pick up both of them when you type in "hirsh ja", so that must mean that your DisplayMember column is hidden, because there's no column in this screen shot that would match that.
I recommend that you get the latest service release and see if that helps. Maybe this was a bug that was already fixed.
How to get the latest service release - Infragistics Community
If that does not help, then we will need a small sample project demonstrating the issue so we can check it out.
This is what my screen looks like. When I click on 'Hirsch 000935' it populates the name and type correctly then when the list closes it selects 'Hirsch 000194'. They have different ID's so I cannot figure out why it does not keep the same person selected.
Should I be using the valuechanged instead of rowselected method?
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.