I saw a similar question, but mine is the opposite. I want the user to be able to enter into the combobox
so I have my UltraCombo as DropDown. Here's my problem. I have a BeforeDropDown event inside which I go to the database and load a datatable. Than I bind that datatable to the UltraCombo datasource. As soon as the DropDown Box opens, the current value is blanked out. Even though the current value exists in the list that was loaded. Anyone else having these problems
The Combo should not blank out in DropDown style, even if the item does not exist on the list.
What version are you using?
Can you create a small sample project demonstrating this?
I still see this behavior in Infragistics 10.2. BeforeDropDown sets the DataSource and right after DataSource is set the Value is still preserved. However, sometime later the internal DoDropDown method seems to clear it.
This issue dates back at least a couple of years as evident by this thread and this other thread http://forums.infragistics.com/forums/p/44392/242028.aspx
I've attached a very simple project that demonstrates the bug and the workaround to make it work.
It's been a while since I posted the sample and I haven't heard anything back. Has anyone looked into this issue? Can you confirm whether you are able to reproduce the problem? Can we expect a fix in upcoming releases?
Thanks,
Hi,
I don't think this is a bug. The problem here is that you are setting the Value of the combo before it has a list. In DropDownList style, the combo can never have a value that does not exist on the list, and since your list is empty, the initial value of "a" you are applying in your sample doesn't really stick.
You need to bind the combo to a list before you can set it's value. Or you can use the SetInitialValue method, instead of setting the control's Value property.
//ultraCombo.Value = "a"; ultraCombo.SetInitialValue("a", "a");
Hi Mike, thanks for looking into this. I'm afraid, though, that it is a bug. What you're saying is correct if the combo was, in fact, using DropDownList style. But if you look at the sample, you'll notice that it's specifically set to DropDown style. So the value can be anything.
Oops, sorry about that. I misread the code.You are right, this does seem like a bug in that case.
I'm going to forward this thread over to Infragistics Developer Support so they can create a case for you and look into this issue more thoroughly.
Hello,
I will be happy to help you out with this issue.
I have created case # CAS-77063-KM3PFG for you to better assist you with this issue going forward. To access the case, simply log into your IG account and click on My Support Activity.
Please let me know if you have further questions in this matter utilizing the case created.