Touch Support in Windows Forms Menu (Menus)
3 Sep 2020 / 1 minute to read
The menu control supports to touch mode to the menu items and other visual elements. The components are also scaled automatically to render the menu items. This can be done by using the
EnableTouchMode property or the menu instance. The below code snippet shows the touch mode is being enabled in the menu.
By default, this property is set to
this.mainFrameBarManager1.EnableTouchMode = true;
Me.mainFrameBarManager1.EnableTouchMode = True
When the property
EnableTouchMode is set to
true, menu items can be selected via general touch action. The below image shows the menu items are being selected with touch action.
Tap and holding on the menu bar or a menu item will display the corresponding context menu for the menu bar. The below screen shot shows the context menu is displayed when tap and hold on the main menu bar.