Closed TaokyleYT closed 1 year ago
I will show all code related to this first import pyautogui as k keys = [ ' ', '!', '"', '#', '$', '%', '&', "'", '(', ')', '*', '+', ',', '-', '.', '/', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', ':', ';', '<', '=', '>', '?', '@', '[', '\\', ']', '^', '_', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '{', '|', '}', '~' ] for prin in keys: k.write(prin) k.press(‘execute’)
import pyautogui as k
keys = [
' ', '!', '"', '#', '$', '%', '&', "'", '(', ')', '*', '+', ',', '-', '.', '/', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', ':', ';', '<', '=', '>', '?', '@', '[', '\\', ']', '^', '_', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '{', '|', '}', '~'
]
for prin in keys:
k.write(prin)
k.press(‘execute’)
and than when I run it it keep showing
X protocol error: <class ‘Xlin.error.BadValue’>: code = 2, resource_id = 0, sequence_number = 15, major_opcode = 133, minor_opcode = 2
anyone know why
Ok so it turns out pyautogui.press(‘execute’) actually is the problem It seems that the ‘execute’ key is not accepted for some reason
I will show all code related to this first
import pyautogui as k
keys = [
' ', '!', '"', '#', '$', '%', '&', "'", '(', ')', '*', '+', ',', '-', '.', '/', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', ':', ';', '<', '=', '>', '?', '@', '[', '\\', ']', '^', '_', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '{', '|', '}', '~'
]
for prin in keys:
k.write(prin)
k.press(‘execute’)
and than when I run it it keep showing
X protocol error: <class ‘Xlin.error.BadValue’>: code = 2, resource_id = 0, sequence_number = 15, major_opcode = 133, minor_opcode = 2
anyone know why