Search code examples
pywinauto

Is it possible to see menu item properties like the help text?


I'm making a script that selects a menu item. With inspect.exe I can see that the menu item as a property "Help Text" but with pywinauto I can't find that property.

Does pywinauto supports that kind of properties?

Edit:This is the code that I'm using to see the properties, this function receives a window open with Application(backend="uia")

    button=window.child_window(title="Button_name", control_type="MenuItem") 
    classification_button = button.child_window(title="Top", control_type="MenuItem")
    b = classification_button_company.get_properties()
    print(b)

output: {u'is_enabled': True, u'is_visible': True, u'texts': [u'Top'], u'class_name': u'NetUIAnchor', u'control_id': None, u'friendly_class_name': u'MenuItem', u'control_count': 1, u'has_keyboard_focus': False, u'is_keyboard_focusable': True, u'rectangle': }


Solution

  • Using the function legacy_properties() I was able to get the help text that I needed