Articles → Pyautogui → LocateCenterOnScreen function in pyautogui

LocateCenterOnScreen function in pyautogui






Purpose





Example







Click to Enlarge



import pyautogui
import time

pyautogui.hotkey('win','r')
pyautogui.typewrite("http://gyansangrah.com/ContactUs.aspx")
pyautogui.press('enter')

# Adding delay so that page gets loaded.
time.sleep(5)

pyautogui.click(pyautogui.locateCenterOnScreen("GS_EMAIL.png"))
pyautogui.typewrite("karan@gyansangrah.com")



Output



Click to Enlarge


Posted By  -  Karan Gupta
 
Posted On  -  Tuesday, May 28, 2019

Query/Feedback


Your Email Id  
 
Subject 
 
Query/FeedbackCharacters remaining 250