ToolStrip.BindingContext ToolStrip.BindingContext ToolStrip.BindingContext ToolStrip.BindingContext Property

定义

获取或设置 ToolStrip 的绑定上下文。Gets or sets the binding context for the ToolStrip.

public:
 virtual property System::Windows::Forms::BindingContext ^ BindingContext { System::Windows::Forms::BindingContext ^ get(); void set(System::Windows::Forms::BindingContext ^ value); };
public override System.Windows.Forms.BindingContext BindingContext { get; set; }
member this.BindingContext : System.Windows.Forms.BindingContext with get, set
Public Overrides Property BindingContext As BindingContext

属性值

注解

BindingContextToolStrip返回单个BindingManagerBase包含的所有数据绑定控件ToolStripThe BindingContext of a ToolStrip returns a single BindingManagerBase for all data-bound controls contained by the ToolStrip. BindingManagerBase保留所有控件都绑定到同一数据源同步。The BindingManagerBase keeps all controls that are bound to the same data source synchronized. 例如,设置Position属性的BindingManagerBase所有数据绑定控件所都指向的基础列表中指定的项。For example, setting the Position property of the BindingManagerBase specifies the item in the underlying list that all data-bound controls point to.

有关创建一个新的详细信息BindingContext并将其分配给BindingContext属性,请参阅BindingContext构造函数。For more information about creating a new BindingContext and assigning it to the BindingContext property, see the BindingContext constructor.

继承者说明

重写时BindingContext属性在派生类中,使用基类的BindingContext属性扩展的基实现。When overriding the BindingContext property in a derived class, use the base class's BindingContext property to extend the base implementation. 否则,必须提供所有的实现。Otherwise, you must provide all the implementation. 不需要重写二者getset访问器BindingContext属性; 您可以根据需要重写仅有一个。You are not required to override both the get and set accessors of the BindingContext property; you can override only one, if needed.

适用于