Most voted "pynput" questions
pynput is a Python library for controlling and manipulating input devices.
Learn more…7 questions
Sort by count of
-
3
votes3
answers5171
viewsRemove string quotes in array
How can I remove single quotes from the result? Typed user teste and key Esc to get out. The program captures keystrokes and saves digit per digit in a list. The list is hereby filled in: lista…
-
2
votes1
answer165
viewsHow to know the direction of the mouse?
I would like to make a program that indicates to which position the mouse is moving (right, left, high, low, right and high, right and low...), but I can’t get a logic that gives me this result.…
-
1
votes1
answer35
viewsGame does not recognize keyboard input by "pynput"
I’m creating a bot to press the "A" key inside a game. Code I am using: from pynput.keyboard import Controller; from time import sleep; keyboard = Controller(); sleep(2) keyboard.press("a");…
-
0
votes1
answer82
viewsHow to click a checkbox when another obscure element is it?
I’m writing a code to automate some processes on the SIAFI site, I couldn’t get Python to click on a checkbox, except by importing the package pynput and using the mouse positioning function with…
-
0
votes0
answers57
viewsPython - about asyncio
I started testing pynput with asyncio, but there’s one problem I can’t solve at all. My code: current = set() def on_press(key): if key == keyboard.Key.up: current.add(key) print('Y') if key ==…
-
0
votes1
answer500
viewsHow to simulate pressing a key for a certain time?
I was trying to make a Python BOT that held the z key for 4 seconds and then released, I tried to use the pynput, but when using the keyboard.press('z'), the command clicked only once and did not…
-
0
votes0
answers19
viewsHow I convert a keylogger to exe
Guys, I’ve been trying for a while to convert my program to exe, I’ve used several ways to do this, so far all gave errors. My code works perfectly in python but in exe it always returns an error. I…