How can I send keystrokes and mouse movements to a specific running program through its PID. I've used both pywinauto and pynput, and they work great, but I want to send keys to a program that is not in focus. I found this question: How to I send keystroke to Linux process in Python by PID? but it never explains what filePath
is a path to, and it doesn't allow for mouse movement. For example, I would like to be able to send keystrokes to an application like Minecraft running in the background rather than having to keep the window in focus. Any help would be appreciated! I am on Windows 10 by the way.
from How can I send keystrokes and mouse movement to a specific PID?
No comments:
Post a Comment