automation using pywinauto to chick on start button

元气小坏坏 提交于 2020-01-06 09:05:04

问题


I am new to python pywinauto and I want to automate a simple step of clicking on windows start button to open control panel and selecting Administrative tools and finally want to check if the check box is checked or not. I'm stuck in the fist step of how to click on windows start button ?


回答1:


from pywinauto import Application

Application().start(r'mmc printmanagement.msc') # Warning! it spawns child process

# connect to that child process
app = Application(backend="uia").connect(path='mmc.exe')

# print main window with the title
print(app.windows())

app.PrintManagement.dump_tree() # print identifiers for further automation


来源:https://stackoverflow.com/questions/54801164/automation-using-pywinauto-to-chick-on-start-button

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!