How would I click the minimize/maximize buttons using pywinauto?
Thanks in advance.
There isn't a direct way at the moment :-(
What you can do instead is to the following
# get the contants and ShowWindow function
from pywinauto.win32defines import SW_MAXIMIZE, SW_SHOW, SW_HIDE
from pywinauto.win32functions import ShowWindow
# this may be enough - it works for Notepad at least
# if that didn't work then hide, maximize and show the window
# you need to save the handle first because after the window is hidden - pywinauto will not find it by default (though it can be made to find it ;-)
handle = app.YourDlg.handle
Great! I'll give it a try. Thanks!
Log in to post a comment.