![]() ![]() | ||
The Binding class represents the simple binding between the property value of an object and the property value of a control. Here is the inheritance hierarchy for this class:
Object Binding
As discussed in the In Depth section of this chapter, you use the Binding class to support a simple binding between the property of a control and either the property of an object or the property of the current object in a list of objects. We saw this example in the In Depth section of this chapter:
DateTimePicker1.DataBindings.Add _ (New Binding("Value", DataSet11, "customers.DeliveryDate"))
The Binding class also lets you format values for display with the Format event and to read formatted values with the Parse event.
You can find the more notable public properties of Binding objects in Table 21.4, and their more notable events in Table 21.5. (This class has no non-inherited methods.)
Property |
Means |
---|---|
BindingMemberInfo |
Gets an object that contains binding information. |
Control |
Gets the associated control. |
DataSource |
Gets the binding's data source. |
IsBinding |
Gets whether the binding is active. |
PropertyName |
Gets/sets the control's data-bound property. |
Event |
Means |
---|---|
Format |
Occurs when a property is bound to a data value. |
Parse |
Occurs when a data-bound control's value changes. |
![]() ![]() | ||