How to disable the right-click context menu on textboxes in Windows, using C#?
try with
textBox1.ShortcutsEnabled =false;
Use the
ShortcutsEnabled
property to enable or disable the following shortcut key combinations and the control’s shortcut menu:
CTRL+Z
CTRL+E
CTRL+C
CTRL+Y
CTRL+X
CTRL+BACKSPACE
CTRL+V
CTRL+DELETE
CTRL+A
SHIFT+DELETE
CTRL+L
SHIFT+INSERT
CTRL+R
Try to do this:
textBoxt1.ContextMenu = new ContextMenu();