How to set the RibbonTabHeader AutomationID to be different than the TabContent?

Bars for WPF Forum

The latest build of this product (v24.1.2) was released 2 months ago, which was before this thread was created.
Posted 1 month ago by eric
Version: 24.1.2

Currently when i set an AutomationID on my RibbonTabItem, the same ID is used for both the RibbonTab content and the RibbonTabHeader.

So i was wondering if there is a way to specify the Header to have a different ID?

Comments (1)

Posted 1 month ago by Actipro Software Support - Cleveland, OH, USA

Hi Eric,

The AutomationId is passed from the RibbonTabItem you define over to the RibbonTabHeader that is actually in the UIA peer tree.  The RibbonTabItem itself shouldn't be appearing in the UIA peer tree though.  The hierarchy is like this:

- ribbon
  - ribbon tabs
    - ribbon tab 'Home' (this is the RibbonTabHeader)
      - ribbon group 'Clipboard'

Could you clarify in more detail what you are doing where the duplicate AutomationId is causing issues?  We'd like to better understand the scenario.  Thank you!

Actipro Software Support

Add Comment

Please log in to a validated account to post comments.