hello,
how can i get the state of the key pressed using GetKeyboardState?
i mean if i press the "W" button on keyboard, to get MessageBox
thank you
get keypress
6 posts
Globally or only when your installer has focus?
globaly
Global keyboard handling requires a hook and NSIS is not the correct tool to use, try AutoHotkey or similar tools.
otherwise, when it has a focus, how to do that?
In Windows, keyboard input is sent to a specific window and to handle it in another fashion means using some type of hook.
If we are talking about custom pages and if Alt+W would be acceptable then you can simply create a 0x0 size button with the text "&W" and handle its onClick.
The WndSubclass plug-in can be used to eavesdrop on keyboard messages sent to a specific window in the installer but the plug-in is difficult to use for beginners.
A "any window" type handler requires a hook and you would have to write your own custom plug-in to pull it off.
If we are talking about custom pages and if Alt+W would be acceptable then you can simply create a 0x0 size button with the text "&W" and handle its onClick.
The WndSubclass plug-in can be used to eavesdrop on keyboard messages sent to a specific window in the installer but the plug-in is difficult to use for beginners.
A "any window" type handler requires a hook and you would have to write your own custom plug-in to pull it off.