Keyboard Hooks?
BlitzMax Forums/BlitzMax Programming/Keyboard Hooks?
| ||
Hi guys! I need to add a global hotkey to a maxgui app so it can be called and execute a function while I'm in another app. Found this code inside the archives but I can't get it to work (BMX 1.45): http://www.blitzbasic.com/codearcs/codearcs.php?code=2248 Example: GHotkey.bmx VInput.bmx Is there another framework I could use or am I missing something? Thanks Grisu Last edited 2011 |
| ||
This alternative method seems to work -- thanks to grable for the extra window event access code! Code's a bit messy; just got it working and posted... EDIT: You'll have to refer to the URL given for the key codes you need to use. EDIT 2: Took out RemoveHotkey, left over from testing the MaxGUI hotkey commands (which only work within the app's own window). Last edited 2011 |
| ||
Thanks a lot for this! Works fine. Is it possible to use a hotkey even from within another fullscreen app? I'd like to play Skyrim e.g. and control my radio app while doing so via hotkeys. Example app: http://188.165.211.46/~knot/prp/hot.zip Hotkeys: Alt & Num+ or Num- to change the volume. |
| ||
I assume so, but I imagine it depends on whether or not the app/game disables keys such as Windows, Alt, etc, which many games do... |