Click here to Skip to main content
15,912,082 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi,
i have a infragistics TabControl .There are 8 Tabs in that..
in each tab i have some design of textboxes,comboboxes, buttons ...etc..
i am calling Tabcontrol.Selectionchanged event but it is firing for so many times .
if i keep e.originalsource.name then i am getting comboboxes also....
i have to prevent this comboboxes from calling tabcontrol events ....
How should i do....


Thanks.....
Posted

1 solution

Hi,

Just catch the event where you want to handle it, and mark the event a handled.

For example:

C#
private void StackPanel_PreviewKeyDown(object sender, KeyEventArgs e)
{
    MessageBox.Show("StackPanel_PreviewKeyDown");
    e.Handled = true;
}


I've found this example at the article:

To bubble or tunnel basic WPF events[^]

Best Regards,

Shai
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900