Uredi

Deli z drugimi prek


FrameworkContentElement.BindingGroup Property

Definition

Gets or sets the BindingGroup that is used for the element.

public:
 property System::Windows::Data::BindingGroup ^ BindingGroup { System::Windows::Data::BindingGroup ^ get(); void set(System::Windows::Data::BindingGroup ^ value); };
[System.Windows.Localizability(System.Windows.LocalizationCategory.NeverLocalize)]
public System.Windows.Data.BindingGroup BindingGroup { get; set; }
[<System.Windows.Localizability(System.Windows.LocalizationCategory.NeverLocalize)>]
member this.BindingGroup : System.Windows.Data.BindingGroup with get, set
Public Property BindingGroup As BindingGroup

Property Value

The BindingGroup that is used for the element.

Attributes

Remarks

A BindingGroup can be used to validate the values of multiple properties of an object. For example, suppose that an application prompts the user to enter an address and then populates an object of type Address, which has the properties Street, City, ZipCode, and Country, with the values that the user provided. The application has a panel that contains four TextBox controls, each of which is bound to one of the object's properties. You can use a ValidationRule in a BindingGroup to validate the Address object. For example, the ValidationRule can ensure that the zip code is valid for the country/region of the address.

Child elements inherit the BindingGroup from their parent elements, just as with any other inheritable property.

Dependency Property Information

Identifier field BindingGroupProperty
Metadata properties set to true Inherits

Applies to