In a windows form application, I register a hotkey to be used throughout the application. However, I would also like a second hotkey to be registered and used, but this isn't too clear as to how to accomplish.
When the form loads, I do this (bearing in mind I have imported the DLLs previously)
Then I use the WndProc method to catch the hotkey. Like so,
This then runs the method CopyToClip().
Any ideas on how I can add another hotkey?
When the form loads, I do this (bearing in mind I have imported the DLLs previously)
Code:
RegisterHotKey(this.Handle, this.GetType().GetHashCode(), 2, (int)'A');
Code:
protected override void WndProc(ref Message m)
{
if (m.Msg == 0x0312)
CopyToClip();
base.WndProc(ref m);
}
Any ideas on how I can add another hotkey?
Comment