selenium - 键盘操作


# 8. 键盘操作
from selenium.webdriver.common.keys import Keys
# send_keys(Keys.CONTROL,'a') Ctrl+A
# send_keys(Keys.CONTROL,'c') Ctrl+C
# send_keys(Keys.CONTROL,'x') Ctrl+X
# send_keys(Keys.CONTROL,'v') Ctrl+V

# 常用的非组合键
# 回车键 Keys.ENTER
# 空格键 Keys.BACK_SPACE
# 删除键 Keys.SPACE
# 制表符 Keys.TAB
# 回退键 Keys.ESCAPE
# 刷新键 Keys.F5

 

posted @ 2018-11-05 16:06  JiaxyGogogo  阅读(135)  评论(0编辑  收藏  举报