import pyautogui
#Step 1 Move to click on the drop down list of State Legislative - Upper
#Chamber
uc = pyautogui.moveTo(1403, 671, duration=1.5)
pyautogui.click()
#Step 2 Move to click on the state in the drop down list.
al_uc = pyautogui.moveTo(1403, 700, duration=0.5)
pyautogui.click()
#Step 3 Move to the down download button
uc_dl = pyautogui.moveTo(1541, 679, duration=1)
pyautogui.click()
对于那些使用Python的人,我被建议使用“pyautogui”模块。人们需要设定点击的位置。
我遇到了两个问题。
(1)我在Chrome上启用了自动下载器。所以,我不得不关闭它,以免在下载和弄乱代码后弹出下载文件。 (2)当从下载按钮进入我的目标列表时,我将鼠标持续时间速度从0.5减少到了1.5。我之所以这么做是因为我的互联网连接速度慢,Chrome在下载,刷新和乱码方面速度很慢。
Link to install pyautogui: http://pyautogui.readthedocs.io/en/latest/install.html