I have a Form with a MenuStrip, where i want to react to "CTRL + P" keystrokes.
The problem is, if the MenuStrip is opened, my Form doesnt get "CTRL + P".
I tried setting Form's KeyPreview = true, and overriding ProcessCmdKey without success...
There is my ProcessCmdKey override:
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
{
if (keyData == (Keys.Control | Keys.P))
{
MessageBox.Show("ProcessCmdKey Control + P");
return true;
}
return base.ProcessCmdKey(ref msg, keyData);
}