Does anyone know how to script fake keyboard and mouse input? I want to make something that automatically runs a program and then pretends to press keys in the program, specifically, Alt-F, I, Enter, Enter.
This is a discussion on Keyboard and mouse scripting within the Windows Programming forums, part of the Platform Specific Boards category; Does anyone know how to script fake keyboard and mouse input? I want to make something that automatically runs a ...
Does anyone know how to script fake keyboard and mouse input? I want to make something that automatically runs a program and then pretends to press keys in the program, specifically, Alt-F, I, Enter, Enter.
Look into the WM_KEYDOWN window message and the mouse_event() function.
"Optimal decisions, once made, do not need to be changed." - Robert Sedgewick, Algorithms in C
Thanks, it turns out that the function SendInput has replaced mouse_event and it does mouse, keyboard, and hardware scripting.