parent
fb9d29e1a1
commit
d9c491fada
@ -0,0 +1,59 @@
|
|||||||
|
###############################
|
||||||
|
#Technology GUI
|
||||||
|
###############################
|
||||||
|
#Init UIDesktop
|
||||||
|
from pyOpenRPA.Robot import UIDesktop
|
||||||
|
|
||||||
|
#Selector: Folder list (framework uia)
|
||||||
|
lGUISelectorFolderList = [
|
||||||
|
{"class_name":"CabinetWClass","backend":"uia"},
|
||||||
|
{"ctrl_index":2},
|
||||||
|
{"ctrl_index":0},
|
||||||
|
{"ctrl_index":2},
|
||||||
|
{"ctrl_index":0}
|
||||||
|
]
|
||||||
|
|
||||||
|
#Highlight the list in folder app (uia framework)
|
||||||
|
UIDesktop.UIOSelector_Get_UIO(lGUISelectorFolderList).draw_outline()
|
||||||
|
|
||||||
|
#Print the children list
|
||||||
|
print(UIDesktop.UIOSelector_Get_UIO(lGUISelectorFolderList).children())
|
||||||
|
|
||||||
|
#Right click
|
||||||
|
UIDesktop.UIOSelector_Get_UIO(lGUISelectorFolderList).right_click_input()
|
||||||
|
|
||||||
|
###############################
|
||||||
|
#Technology Selenium
|
||||||
|
###############################
|
||||||
|
#Init the selenium driver
|
||||||
|
import os
|
||||||
|
#Add chrome webdriver to PATH system enviroment (need to selenium)
|
||||||
|
os.environ["PATH"]=os.environ["PATH"]+";C:\\Abs\\Archive\\scopeSrcUL\\OpenRPA\\Resources\\SeleniumWebDrivers\\Chrome\\chromedriver_win32 vchromedriver_win32 v79.0.3945.36\\"
|
||||||
|
#Import selenium
|
||||||
|
from selenium import webdriver
|
||||||
|
from selenium.webdriver.common.keys import Keys
|
||||||
|
driver = webdriver.Chrome()
|
||||||
|
|
||||||
|
#Open URL
|
||||||
|
driver.get("http://www.python.org")
|
||||||
|
|
||||||
|
#Find the search input
|
||||||
|
elem = driver.find_element_by_name("q")
|
||||||
|
|
||||||
|
#Type text in search imput
|
||||||
|
elem.send_keys("pycon")
|
||||||
|
|
||||||
|
#Submit the search
|
||||||
|
elem.send_keys(Keys.RETURN)
|
||||||
|
|
||||||
|
#Close the driver
|
||||||
|
driver.close()
|
||||||
|
|
||||||
|
###############################
|
||||||
|
#Technology Image & Mouse
|
||||||
|
###############################
|
||||||
|
...
|
||||||
|
###############################
|
||||||
|
#Technology Keyboard & Clipboard
|
||||||
|
###############################
|
||||||
|
...
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in new issue