Hi,
I have an UltraCombo.
I want to do something whenever the selection was changed.
Problem is, that UltraCombo doesn't have this event.
ValueChange event occures even if I didn't change the selection, so it doesn't help.
Which event can I use instead?
Thanks a lot,Yael
There is no good way to differentiate whether ValueChanged occurred because of a user typing or selecting an item from the list.
You could use the IsItemInList method to determine if the new value is on the list, but this can still occur when the user types something that matches an item on the list.
If you don't want the user to be able to type into the combo and only allow them to select from the list, then you can set the DropDownStyle property to DropDownList. This is the same way it works in the MS Combo.
I have a requirement with UltraCombo. I have added ValueChangedEvent handler to know which value selected and I need to do some work with that value. But It is valid only if the value is selected from the list. However I observed that this handler is called even when I type a character in the field. As I said, I need handler only when some one selected a value from the ComboBox.
For example, I have list of values(ABC, DEF and GHI), Suppose if I select a value from the list, I will get either ABC or DEF or GHI. But some one may type ABC or DEF or GHI in the field as well. I need a handler which should be called when I select a value from the list or when I type ABC(completely) but not for single character typing.
One way to do this, we need to disable typing mechanism and add just a Selection change handler.But I did n't see any such handler.
Can anyone point me to correct solution.
Thanks,
Sanjeev.
Why not just use the Enter event instead of BeforeDropDown?
I am facing an issue in similar line.
I have a method that wires to BeforeDropDown event to remove the already used option of drop down. It has been working fine but when the user use the Tab to navigate to the drop down (within UltraGrid) and Key Down to select the drop down the event attached to eforeDropDown won't fire.
How can I get this event to fire? I don't see an Key down or focus or Enter event handler where I can wire my event.
You answe will be greately appreciated.
Thanks!The solution was really simple:
if
(ultraCombo.Focused)....MyCode...