SavinaRoja / PyUserInput

A module for cross-platform control of the mouse and keyboard in python that is simple to install and use.
GNU General Public License v3.0
1.07k stars 244 forks source link

'PyKeyboard' object has no attribute 'enter_key' #123

Open yzw1993 opened 3 years ago

yzw1993 commented 3 years ago

!/usr/bin/python

-- coding: UTF-8 --

from pykeyboard.mac import PyKeyboard from pymouse import PyMouse import time

m = PyMouse() k =PyKeyboard() print(m.position()) time.sleep(1) m.click(766,1375) time.sleep(0.1) m.click(1138,39) time.sleep(0.1) k.type_string("www.google.com") k.tap_key(k.enter_key)

mac.py Traceback (most recent call last): File "/Users/yzw/PycharmProjects/pachong/mouse.py", line 16, in k.tap_key(k.enter_key) AttributeError: 'PyKeyboard' object has no attribute 'enter_key'