Original Post
I have added hot keys to an application of mine. These hot keys need to be acivatable from anywhere in the system, not just when my application has focus. I installed a keyboard hook, and all works well, except if the desktop has focus, I am not getting the key. If any other app has focus, this works beautifully, but if the user is just clicking around in the desktop and hitting keys, nothing happens. Anyone have any idea why?
Here''s how I''m called SetWindowsHook:
hKeyHook = SetWindowsHookEx(WH_KEYBOARD, (HOOKPROC)KeyHookProc, hDllModule, 0);
if( hKeyHook == 0 )
return 0;