UI Automation Support
With the Q3 2024 version of our controls, RadNavigationView supports UI Automation. The current implementation of UI Automation for RadNavigationView is similar to the MS WinForms TabControl implementation with some extended functionality. The main goal of this implementation is to ensure compliance with accessibility standards and to provide a common practice for automated testing.
This functionality is enabled by default. To disable it, you can set the EnableUIAutomation property to false.
Relevant Properties
The table below outlines the UI Automation properties most important for understanding and interacting with RadNavigationView control.
RadNavigationView
- AutomationElementIdentifiers.AutomationIdProperty.Id
- AutomationElementIdentifiers.IsKeyboardFocusableProperty.Id
- AutomationElementIdentifiers.NameProperty.Id
- AutomationElementIdentifiers.LabeledByProperty.Id
- AutomationElementIdentifiers.ControlTypeProperty.Id => ControlType.Tab.Id
- AutomationElementIdentifiers.LocalizedControlTypeProperty.Id => "tab"
- AutomationElementIdentifiers.IsContentElementProperty.Id
- AutomationElementIdentifiers.IsControlElementProperty.Id
- AutomationElementIdentifiers.OrientationProperty.Id
- AutomationElementIdentifiers.ClassNameProperty.Id
- AutomationElementIdentifiers.IsEnabledProperty.Id
- AutomationElementIdentifiers.HasKeyboardFocusProperty.Id
- AutomationElementIdentifiers.IsSelectionPatternAvailableProperty.Id
- AutomationElementIdentifiers.IsExpandCollapsePatternAvailableProperty.Id
Hamburger Button Element
- AutomationElementIdentifiers.NameProperty.Id
- AutomationElementIdentifiers.AutomationIdProperty.Id => "Hamburger_Button"
- AutomationElementIdentifiers.LocalizedControlTypeProperty.Id => "button"
- AutomationElementIdentifiers.ControlTypeProperty.Id => ControlType.Button.Id
- AutomationElementIdentifiers.IsControlElementProperty.Id
- AutomationElementIdentifiers.IsContentElementProperty.Id
- AutomationElementIdentifiers.ClassNameProperty.Id
- AutomationElementIdentifiers.HelpTextProperty.Id
- AutomationElementIdentifiers.IsInvokePatternAvailableProperty.Id
- AutomationElementIdentifiers.ClickablePointProperty.Id
- AutomationElementIdentifiers.IsEnabledProperty.Id
Navigation View Items
- AutomationElementIdentifiers.AutomationIdProperty.Id => this.owner.Page.Name + "_item"
- AutomationElementIdentifiers.NameProperty.Id
- AutomationElementIdentifiers.ClickablePointProperty.Id
- AutomationElementIdentifiers.LabeledByProperty.Id
- AutomationElementIdentifiers.ControlTypeProperty.Id => ControlType.TabItem.Id
- AutomationElementIdentifiers.LocalizedControlTypeProperty.Id => "tab item"
- AutomationElementIdentifiers.IsControlElementProperty.Id
- AutomationElementIdentifiers.IsContentElementProperty.Id
- AutomationElementIdentifiers.IsKeyboardFocusableProperty.Id
- AutomationElementIdentifiers.ClassNameProperty.Id
- AutomationElementIdentifiers.IsEnabledProperty.Id
- AutomationElementIdentifiers.HasKeyboardFocusProperty.Id
- AutomationElementIdentifiers.IsSelectionItemPatternAvailableProperty.Id
Supported Control Patterns
The following section outlines the supported automation patterns for the RadNavigationView control and its constituent elements.
RadNavigationView
Hamburger Button Element
Navigation View Items
Custom Automation Provider
The RadNavigationView control expose CreateUIAutomationProvider() method that can be overriden to replace the default RadNavigationViewUIAutomationProvider class with your own implementation of the IRawElementProviderFragmentRoot interface.