AutomationElement.CultureProperty Field

Definition

Identifies the culture property.

C#
public static readonly System.Windows.Automation.AutomationProperty CultureProperty;

Field Value

Examples

The following example retrieves the current value of the property.

C#
System.Globalization.CultureInfo culture =
   autoElement.GetCurrentPropertyValue(AutomationElement.CultureProperty)
   as System.Globalization.CultureInfo;

Remarks

This identifier is used by UI Automation client applications. UI Automation providers should use the equivalent identifier in AutomationElementIdentifiers.

Within the Windows Presentation Foundation (WPF) framework, the default value reported will always be en-US because the .NET Framework automatically defaults to English. For other user interface (UI) frameworks, this property must be explicitly set or it will not be exposed.

This property can exist on a per-control basis, but typically is only available on an application level.

Return values of the property are of type CultureInfo.

Applies to

Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

See also