iT邦幫忙

0

家齊高中資訊研究社 社課內容1

TUT 2021-09-30 13:45:39303 瀏覽
  • 分享至 

  • xImage
  •  

1.練習打字

Typing Club練習打字

2.練習上傳檔案

https://ithelp.ithome.com.tw/upload/images/20210930/20142610RRkbfaxQWf.png

3.下載及使用pyperclip模組

https://ithelp.ithome.com.tw/upload/images/20210930/20142610Ov7jsRiVyV.png

4.下載及使用pyautogui模組

結合前面的上傳檔案及pyperclip外加whereisthemouse,pyautogui來做出自動開啟檔案及查詢的功能

import pyautogui
import pyperclip

try:
    with open ("d:/aaa.txt","r",encoding='utf8') as file:
        file=file.readlines()
    for L in file:
        pyperclip.copy(L.strip()) # L.strip() #刪除頭尾空格
        pyautogui.click((175,48))
        pyautogui.time.sleep(2.0)
        pyautogui.hotkey('ctrl','a')
        pyautogui.time.sleep(2.0)
        pyautogui.hotkey('ctrl','v')
        pyautogui.hotkey('enter')
except:print("error")


圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言