Name

PropertyManager

Synopsis

This class, derived from BindingManagerBase represents a bag of Binding objects for a simple property-like data source.

While CurrencyManager deals with lists of objects, the PropertyManager is bound to a single item. Therefore, it is hardwired to look like a list with one entry (at Position zero).

It ensures that all the Binding objects update correctly as the value of this single property changes, by binding to an appropriately named event. For example, a component providing a Text property must also raise a TextChanged event.

See Binding for more information on the data-binding architecture.


public class PropertyManager : BindingManagerBase {

// Public Constructors

   public PropertyManager();

// Public Instance Properties

   public override int Count{get; }

// overrides BindingManagerBase

   public override object Current{get; }

// overrides BindingManagerBase

   public override int Position{set; get; }

// overrides BindingManagerBase

                  // Public Instance Methods

   public override void AddNew();  // overrides BindingManagerBase

   public override void CancelCurrentEdit();  // overrides BindingManagerBase

   public override void EndCurrentEdit();  // overrides BindingManagerBase

   public override PropertyDescriptorCollection GetItemProperties();  // overrides BindingManagerBase

   public override void RemoveAt(int index);  // overrides BindingManagerBase

   public override void ResumeBinding();  // overrides BindingManagerBase

   public override void SuspendBinding();  // overrides BindingManagerBase ...

Get .NET Windows Forms in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.