dannyn

dannyn

  • NA
  • 3
  • 0

Passing control events to parent container ?

Jan 26 2006 3:40 PM

How do you have the container handle its child controls' events (or other controls) ?

For example, I got my own (scrollable) UserControl, and I dynamically create some comboboxes, the problem is that once the focus is on one of the comboboxes, any scrolling that the user attempts to do(using the mouse wheel) are handled by the combobox itself (scrolling through its items). I want the usercontrol to get the scrolling  event (and scroll) even if it doesn't currently have the focus. 

Sometimes I just want events to pass to another control : I have a ContextMenu shown when a user clicks somewhere inside the usercontrol. When the user presses TAB, I , again, want the UserControl to handle it (using ProcessCmdKey override), but instead, the Tabbing is made in the menu.

Any ideas?

Please help me !

Answers (1)