'Declaration Public Function Add( _ ByVal binding As ScheduleDataBinding _ ) As Integer
public int Add( ScheduleDataBinding binding )
Exception | Description |
---|---|
System.ArgumentNullException | Thrown when the supplied binding object is null (Nothing in Visual Basic .NET). |
System.InvalidOperationException | Thrown when the supplied binding has duplicated a type of ScheduleDataBinding that has already been previously added. |
The precedence in which ScheduleDataBindings are processed in the DataBindingCollection matches the order in which they were added. Developers should therefore add those ScheduleDataBindings which they want to take precedence over later data binding objects to the DataBindingCollection first.
In order to supercede the precedence defined by the base data provider class, it is sometimes necessary to call Clear on the DataBindingCollection and re-add the ScheduleDataBindings (including those present by default for a particular operation) to the collection.
The Add method performs additional checking to ensure the uniqueness of each type of ScheduleDataBinding that has been registered.
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2