I am trying to interact with windows using pywinauto. Here's the code snippet I am using:
top_windows = Desktop().windows()
for w in top_windows:
print(w.window_text())
print(w.get_properties())
w.draw_outline()
I successfully retrieve the window I need and use class_name from the properties I see in w.get_properties(). However, when I try to find the window using this class_name, I encounter a pywinauto.findbestmatch.MatchError.
NOTE: in propreties I have 'is_visible': False, 'is_enabled': True and 'automation_id': ''
Reference to the Pywinauto documentation Additionally, I am attempting to access properties like this:
Properties = Desktop().Common_Files_Properties
Properties.print_control_identifiers()
Can anyone help me understand why I am getting the MatchError and how to resolve it?
I tried using class_name from w.get_properties() to find a specific desktop window, expecting it to match and work without errors. However, I encountered a pywinauto.findbestmatch.MatchError
MatchErrorby editing your question. Such traceback contains line numbers which are very useful to find the problem. Also I don't see the failed piece of code which leads toMatchError.