asweigart / pyautogui

A cross-platform GUI automation Python module for human beings. Used to programmatically control the mouse & keyboard.
BSD 3-Clause "New" or "Revised" License
10.22k stars 1.24k forks source link

write() and typewrite() missing characters #826

Open KnowScratcher opened 9 months ago

KnowScratcher commented 9 months ago

I wrote this code

pyautogui.press("/")
pyautogui.write("123456789 !@#$%^&*(")
pyautogui.press("enter")

But I open the notepad and then let it type, this is what i got

/123456 !@$%^*(
mikigo commented 9 months ago

Perhaps the input is too fast, the parameter interval of the number of seconds in between each press, 0.0 by default, for no pause in between presses,try pyautogui.write("123456789 !@#$%^&*(", interval=1)