Is it possible to intercept and handle clicks on a particular BarItem?

Hi,

Just wondering if it's possible to alter the behavior when user clicks on a particular bar item? I know how to get notification when a BarItem is clicked (MainFrameBarManager.ItemClicked), but it does not allow me to cancel the execution of the 'original' event handler.

For instance, it could be achieved by introducing the Handled property:

mainFrameBarManager.ItemClicked += (o, args) =>
{
if (args.ClickedBarItem.Text = "Save")
{
MySave();
args.Handled = true; // barItem.Click event will not be raised
}
};

Thanks!
Andrew

2 Replies

AD Administrator Syncfusion Team February 9, 2010 03:35 PM UTC

Wrong forum, it should go to WinForms - can anyone move it there, please?


RB Rajasekar B Syncfusion Team February 12, 2010 12:36 PM UTC

Hi Andrew,

Thank you for using syncfusion products.

In the current architecture we cannot cancel the baritem's click event. We have logged a feature request to add a property as you have suggested. This will be available in our future product releases. Let me know if you have any questions.

Thanks,
Rajasekar

Loader.
Up arrow icon