TemplateVisualStateAttribute.GroupName Özellik
Tanım
Önemli
Bazı bilgiler ürünün ön sürümüyle ilgilidir ve sürüm öncesinde önemli değişiklikler yapılmış olabilir. Burada verilen bilgilerle ilgili olarak Microsoft açık veya zımni hiçbir garanti vermez.
Durumun ait olduğu grubun adını alır veya ayarlar.
public:
property System::String ^ GroupName { System::String ^ get(); void set(System::String ^ value); };
public string GroupName { get; set; }
member this.GroupName : string with get, set
Public Property GroupName As String
Özellik Değeri
Durumun ait olduğu adı VisualStateGroup .
Örnekler
Aşağıdaki örnek, denetimin sınıf imzasını NumericUpDown gösterir. Bu örnek, denetimin NumericUpDown dört görsel durum kullandığını belirtir. ve adlı iki durum adlandırılmış içindedirPositiveNegative.VisualStateGroupValueStates name Focused ve adlı diğer iki durum adlandırılmış içindedir UnfocusedVisualStateGroup.FocusedStates Tüm örnek için bkz. Özelleştirilebilir Görünüme Sahip Bir Denetim Oluşturma.
[TemplatePart(Name = "UpButtonElement", Type = typeof(RepeatButton))]
[TemplatePart(Name = "DownButtonElement", Type = typeof(RepeatButton))]
[TemplateVisualState(Name = "Positive", GroupName = "ValueStates")]
[TemplateVisualState(Name = "Negative", GroupName = "ValueStates")]
[TemplateVisualState(Name = "Focused", GroupName = "FocusedStates")]
[TemplateVisualState(Name = "Unfocused", GroupName = "FocusedStates")]
public class NumericUpDown : Control
<TemplatePart(Name:="UpButtonElement", Type:=GetType(RepeatButton))> _
<TemplatePart(Name:="DownButtonElement", Type:=GetType(RepeatButton))> _
<TemplateVisualState(Name:="Positive", GroupName:="ValueStates")> _
<TemplateVisualState(Name:="Negative", GroupName:="ValueStates")> _
<TemplateVisualState(Name:="Focused", GroupName:="FocusedStates")> _
<TemplateVisualState(Name:="Unfocused", GroupName:="FocusedStates")> _
Public Class NumericUpDown
Inherits Control
Açıklamalar
GroupName özelliği bir VisualStateGroup.Name nesnenin VisualStateGroup özelliğine karşılık gelir. Bir VisualStateGroup öğesinin ait olduğu yeri VisualState belirtmek için özelliğini ayarlayınGroupName.