In an UltraComboEditor control I am using, the list object has (amongst other fields) two string fields, Name and Shortname. At the moment, I have the following set up:
DropDownStyle = DropDownStyle.DropDown
AutoCompleteMode = AutoCompleteMode.SuggestAppend
DisplayMember = "Shortname"
ValueMember = BindableValueList.USE_LISTOBJECT_AS_VALUEMEMBER;
What I would like to do is adjust the control so to add recognition by Name as well as Shortname. So if I have a list object that has Name = "Christopher D Bozzuto" and Shortname = "CDB", if I type Christopher into the editor, CDB should be in the dropdown. Is there a property where I can change the way it compares the text to the list object? Or a way to add multiple fields? Or is there any way to do this at all?
Hi,
No, I don't think there is currently any way to do this. You could try turning off AutoCompleteMode and then re-implement it yourself, but that would not be a trivial task by any means.
I recommend that you Submit a feature request to Infragistics
I submitted a feature request.
I tried reconstructing a custom ultra combo editor by starting with an UltraTextEditor with a DropDownEditorButton holding an UltraDropDown. It is becoming apparent that this is an enormous task; the dropdown is just too stupid by default. Never mind the autocomplete functionality, there's a hundred other things I'd have to get working first that the UltraComboEditor does automatically now.
Is there a better way of going about creating this custom control than creating it from whole cloth? Or maybe a better choice of controls to make it easier? I was expecting much more automatic behavior from the UltraDropDown. I really just want it to behave like a value list, just like the dropdown of UltraComboEditor. I spent a lot of time trying to make the UltraDropDown behave this way with only limited success. I don't want the UI behavior to be different from the normal dropdown - I just want to change the list objects that are present. I just want a way to override the logic in the AutoComplete dropdown without having to reverse engineer the entire control that Infragistics has already built for UltraComboEditor. Is there perhaps a way to capture the dropdown subcontrol when the autocomplete mode kicks in and just feed it a datasource of my choosing? I think I could use that as a workaround if it were possible to do.
There is no way that I know of to intercept the autocomplete behavior and modify it.
If you are going to use an UltraTextEditor, then I would use a DropDownEditorButton with a WinGrid on it, not an UltraDropDown.
What kind of problems did you have with that? There are basically two things you would need to handle - one is setting the Text of the UltraTextEditor when the user selects an item from the grid and the other is selecting a row in the grid when the user drops down the list.
These aren't exactly trivial, but they are not monumentally difficult, either.
Another option is to keep using UltraCombo and just turn off the AutoComplete and then handle the key events yourself to find a matching item.