|
What you're asking for can't be done with 100% reliability. There are ways to send falsified keyup/down messages to non-active windows, but depending on how the application itself responds to those messages (whether it trusts the message, or whether it queries the keyboard state directly), that approach may not work. Typically, applications that need a better view of what's happening on the keyboard will use more strict checking of the keyboard state, which will quickly make your attempts to fake keypresses to a background app fall apart as the actual keyboard state won't match the fake messages you're trying to send. That said though, you can use PostMessage to send WM_KEYUP, WM_CHAR, and WM_KEYDOWN messages and maybe get away with it; though given the nature of the Remote Desktop Client, I'm not very optimistic it'll work since that feels like an application that's going to want to know the full keyboard state just by the very nature of what it does. What I'd suggest instead is to run your RDP session in a VM, then use a more traditional anti-idle utility within that VM.
|
# ¿ Jun 23, 2017 21:31 |
|
|
# ¿ Apr 28, 2024 23:44 |