Hello
This might be simple, but I can't seem to find the answer, I have an ultracombo as the editor of one of the cells of my grid, the values of the ultra combo is a grid itself (bound to a list of objects). The ultracombo width on the cell matches the cell width, but the grid that dropdowns with it does not. It seems that the width of the grid inside the cell seems to match the width of the originating ultracombo. I've already tried ultracombo.DisplayLayout.AutoFitStyle = ResizeAllColumns. I also set the ultra combo DropDownWidth = 0.
See the control setup in the pic attached (the actual ultracombo on top on the final form will not be visible)
Thank you
Hello,
I was able to observe the UltraCombo dropdown width mismatch behavior that you mentioned. You can work around this by using an UltraComboEditor instead of an UltraCombo. I have tested this behavior with an UltraComboEditor and when I open the dropdown the width of the Grid matches with the Cell width.
Please try the above suggestion and let me know if I may be of further assistance.
Sincerely,Sahaja KokkalagaddaAssociate Software Developer
We need it to be an UltraCombo because we need to display the value selection as a multicolumn grid. Isn't there a way to make it work with the UltraCombo control?
If it does not filter the same way the ultra combo does, that is, only showing the elements that comply to the search criteria instead of just focusing on an index inside the list, then the UltraDropdown is just not an option for us. Can you please tell me if there is a workaround I can use on the UltraCombo for it to have the correct resize behavior?
Hi,
The only workaround I can think of is that you could handle the grid's BeforeCellListDropDown event and set the DropDownWidth on the UltraCombo to exactly the width of the column before it drops down.
But I don't understand why you are having a problem with the "filtering". I'm not even sure what you mean by "filtering" in this context. But as I said, the UltraCombo and UltraDropDown derive from the same base class are have nearly identical functionality. So unless you are using editor buttons or something like that, there's no reason why you can't use UltraDropDown. I'm guessing that by "filtering" you are referring to the AutoSuggest functionality, and I already explained how to get the same behavior. You have to set properties on the grid column instead of on the UltraCombo, that's all.
I'm attaching sample code so you can see what my problem is. Basically I have two columns: Detail1 and Detail2. Both use the same underlying datasource.
Detail1 uses an UltraCombo control while Detail2 uses an UltraDropdown
I don't know what I'm doing wrong but I cannot make the UltraDopdown on Detail2 to work the way the ultraCombo on Detail1 does
Main differences:
- When you start typing on Detail1 the dropdown shows the grid immediately (which I like)
- Upon typing on Detail1, the combo starts showing only the entries that match what is being typed. Detail2 shows always all the items in the dropdown, it just seems to change the index of the item selected (see ultracombo suggest.png and ultradropdown suggest.png)
- Even though both columns are set to use AutoCompleteMode.SuggestAppend and AutoSuggestFilterMode.Contains, only the values on Detail1 are being searched as "contains" the ones on Detail2 seem to only work as StartsWith (I really need it to work as Contains)
The only thing the UltraDropdown is doing correctly is the fact that it is resizing the grid according to the size of the cell, which is the one thing I need in the UltraCombo
Can you please tell me what I'm doing wrong?
I'm using Infragistics version 17.1
Thanks
My apologies. While working with your sample, it appears that UltraDropDown does not support AutoSuggest. I'm not sure why that is. It works with UltraCombo and with a ValueList, but for some reason, UltraDropdown just doesn't support it.
So going back to your original question about the dropdown width, when I run your sample, the width of the dropdown matches the width of the cell in every case. I tried making the column width larger or smaller, but it seems to work whatever I do. So I'm now confused about what the original issue is. In fact, it's even the same in the screenshots you included here.
Under what circumstances does the width of the dropdown not match the width of the column?
Okay, I think I see the issue now. The problem here is not with the size of the DropDown window, it's the size of the columns within the dropdown. You are setting AutoFitStyle and the dropdown appears to be using the width of the UltraCombo control on the form instead of the width of the dropdown when AutoFittting the columns. So I think that's a bug in the control that we will need to look into.
For a workaround, you could turn off AutoFitColumns and then handle AfterCellListDropDown and then explicitly set the width of each column. But it would be tricky, since you would have to account for the scrollbars.