Menu Items C# Events of Menus WinForms Control
Kettic Menu WinForms Control contains various MenuItem Events for C# developers to apply this control to their applications. They need to handle the events of the menu items to add, set, and remove the menus they are designing. In this article, we are going to demonstrate how to use the key C# events for the KetticMenuItem object.
Significant Events for KetticMenuItem
The Click event is the most significant event for KetticMenuItem object and is fired when the user chooses the menu item or builds the shortcut key. The other two events, ChangeToggleState and ChangedToggleState, are able to display check marks and will be fired when applying removing a check mark from the KetticMenuItem object. How to Handle the ChangeToggleState event in C#.NET
To handle the ChangeToggleState event, pass a ChangeStateEventArgs parameter with properties for NewValue, OldValue and Cancel. The NewValue and OldValue are ToggleState enumeration types with values of Intermediate, On and Off. When the Cancel is enabled, the checkbox will not change state and the ToggleStatedChanged event will not fire.
C# code for handling the ChangeToggleState event in .NET project
How to Handle ChangedToggleState event in C#.NET
The ChangedToggleState event will be fired while the checkbox state changing. Pass the ChangedStateEventaArgs parameter to this event handler with one of the ToggleState properties of On, Off or Intermediate.
C# code for handling the ChangedToggleState event
How to Handle KetticMenuComboItem Events in C#.NET
KetticMenuComboItem passes EventArgs with ComboBoxElement property and the C# code below will apply the ComboBoxElementChangedIndexSelected event to get the value of combo box that currently selected.
KetticMenuContentItem
To handle the KetticMenuContentItem events, assign it to the Kettic Menu control. The C# code below demonstrates how to handle the event and attach a Click button item.
| ![]() UI Controlsfor Windows Forms .NET WinForms UI Overview.NET WinForms UI Features.NET WinForms UI GuideC# WinForms UI DesignVB.NET WinForms UI DesignWinForms UI Controls WinForms Buttons UI Control WinForms Calendar UI ControlWinForms Carousel UI ControlWinForms Chart UI ControlWinForms Clock UI ControlCommandBar UI ControlWinForms Dock UI ControlDesktop Alert UI ControlDropDown List UI ControlWinForms Editor UI ControlForms and Dialogs UI ControlWinForms GridView UI ControlWinForms ListView UI ControlWinForms Menu UI ControlMenu - Get Started in C#Menu - Menu DesignerMenu - Working with ItemsAdd / RemoveMulti-Line TextEventsMenu - Styling & AppearanceMenu OrientationMenu BackgroundMenu Item ImagesAnimation EffectsMenu - Menu MergeMenu - Application MenuMenu - Context MenuWinForms ComboBox UI ControlWinForms PageView UI ControlPanels and Labels UI ControlWinForms Panorama UI ControlWinForms PDFViewer UI ControlWinForms Property Grid UI ControlWinForms Ribbon UI ControlWinForms PivotGrid UI ControlWinForms RichTextBox UI ControlWinForms Rotator UI ControlWinForms Scheduler UI ControlWinForms Shortcuts UI ControlWinForms SpellChecker UI ControlWinForms Track & Status UI ControlWinForms TreeView UI ControlWinForms Wizard UI ControlWinForms Test UI ControlWinForms Theme UI Control |