When the list is dropped down an the mouse hovers over an item in the drop-down list, the item becomes highlighted but the selected value shown in the text box does not change unless the item is clicked. I am looking for a way to modify the mouse over behavior in a control that inherits from ComboBox. I tried overriding function like OnMouseEnter & OnMouseMove etc.
When the list is dropped down an the mouse hovers over an item in
Share
You can do it by overriding OnMouseMove. The OriginalSource property of the MouseEventArgs will give you the element directly under the mouse. You can use ContainerFromElement to get the ComboBoxItem that contains that element and then ItemContainerGenerator.ItemFromContainer to get the item to select: