So i'm attempting to make an auto clicker for something, with a gui, im using .net framework for a windows forms project. How ever i'm not sure how to set up a hot key for when the process isn't tabbed in.
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
{
if (keyData == (Keys.Control | Keys.F))
{
// Code
return true;
}
return base.ProcessCmdKey(ref msg, keyData);
}
is what i'm using, it correctly detects the key press when the gui is tabbed in how ever when it's tabbed out it doesn't work.
With windows forms how do you detect key presses when the app isn't tabbed in