Control.BindingContainer Control.BindingContainer Control.BindingContainer Control.BindingContainer Property

定义

获取包含该控件的数据绑定的控件。Gets the control that contains this control's data binding.

public:
 property System::Web::UI::Control ^ BindingContainer { System::Web::UI::Control ^ get(); };
[System.ComponentModel.Bindable(false)]
[System.ComponentModel.Browsable(false)]
public System.Web.UI.Control BindingContainer { get; }
member this.BindingContainer : System.Web.UI.Control
Public ReadOnly Property BindingContainer As Control

属性值

包含该控件的数据绑定的 ControlThe Control that contains this control's data binding.

注解

BindingContainer属性包含Control对对象的引用,该对象包含当前控件的数据绑定信息。The BindingContainer property contains a reference to the Control object that contains the data-binding information for the current control.

除了控件是模板的一部分时NamingContainer ,属性与属性相同。BindingContainerThe BindingContainer property is the same as the NamingContainer property, except when the control is part of a template. 在这种情况下BindingContainer ,属性设置Control为定义模板的。In that case, the BindingContainer property is set to the Control that defines the template.

适用于

另请参阅