Binding.BindingManagerBase Property

Gets the BindingManagerBase for this Binding.

Namespace: System.Windows.Forms
Assembly: System.Windows.Forms (in system.windows.forms.dll)

public BindingManagerBase BindingManagerBase { get; }
/** @property */
public BindingManagerBase get_BindingManagerBase ()

public function get BindingManagerBase () : BindingManagerBase

Not applicable.

Property Value

The BindingManagerBase that manages this Binding.

Use the BindingManagerBase to iterate through a data-bound list by incrementing or decrementing the Position property. The BindingManagerBase class is abstract. The CurrencyManager class, which manages data-bound lists, inherits from the BindingManagerBase class.

The following code example gets the BindingManagerBase of every Binding on the form, and prints the Position property for each BindingManagerBase.

private void PrintPositions()
{
   foreach(Control c in this.Controls)
   {
      foreach(Binding xBinding in c.DataBindings)
      {
         Console.WriteLine
         (c.ToString() + "\t Position: " + 
         xBinding.BindingManagerBase.Position);
      }
   }
}


private void PrintPositions()
{
    for (int iCtr1 = 0; iCtr1 < this.get_Controls().get_Count(); iCtr1++) {
        Control c = this.get_Controls().get_Item(iCtr1);
        for (int iCtr2 = 0; iCtr2 < c.get_DataBindings().get_Count(); 
            iCtr2++) {
            Binding xBinding = c.get_DataBindings().get_Item(iCtr2);
            Console.WriteLine((c.ToString() + "\t Position: "
                + xBinding.get_BindingManagerBase().get_Position()));
        }
    }
} //PrintPositions

private function PrintPositions()
{
   for(var i : int = 0; i < this.Controls.Count; i ++)
   {
      for(var j : int = 0; j < this.Controls[i].DataBindings.Count; j++)
      {
         Console.WriteLine
         (this.Controls[i].ToString() + "\t Position: " + 
         this.Controls[i].DataBindings[j].BindingManagerBase.Position);
      }
   }
}


Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0, 1.1, 1.0

.NET Compact Framework

Supported in: 2.0, 1.0

Community Additions

ADD
Show: