Name Property
Collapse the table of content
Expand the table of content

VisualState.Name Property

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Gets the name of the VisualState.

Namespace:  System.Windows
Assembly:  System.Windows (in System.Windows.dll)
XMLNS for XAML: Not mapped to an xmlns.

public string Name { get; }
<VisualState x:Name="stateName"/>

XAML Values

stateName

The name of the VisualState. Name is a read-only property, so specify the name of the VisualState by setting x:Name.

Property Value

Type: System.String
The name of the VisualState.

Control authors specify which VisualState objects the control expects to find in its ControlTemplate by putting the TemplateVisualStateAttribute on its class signature. ControlTemplate authors define new VisualState objects and set the Name property to the value specified by the TemplateVisualStateAttribute.Name property.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2017 Microsoft