Version

BindingNotificationsSuspended Property

Indicates whether IBindingList related notifications are suspended.
Syntax
'Declaration
 
Public ReadOnly Property BindingNotificationsSuspended As Boolean
public bool BindingNotificationsSuspended {get;}
Example
Following code shows how to suspend IBindingList.ListChanged notifications temporarily on an UltraDataSource.

Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinDataSource
Imports Infragistics.Win.UltraWinGrid


    Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button1.Click
        ' SuspendBindingNotifications and ResumeBindingNotifications are used when
        ' performing a large number of updates to the data. What it does is that it
        ' prevents the UltraDataSource from firing ListChanged notifications on the
        ' IBindingList implementation so any bound controls do not process the 
        ' individual changes. When ResumeBindingNotifications is called, 
        ' UltraDataSource will fire ListChanged with Reset as the type specifying
        ' to the bound controls that they should reget the data for all rows. This
        ' can be more efficient than firing notifications for individual changes
        ' when there are lot of changes being made.
        '
        Try
            ' Suspend IBindingList ListChanged notifications.
            Me.UltraDataSource1.SuspendBindingNotifications()

            ' Value of BindingNotificationsSuspended property should be true after
            ' calling SuspendBindingNotifications method.
            Debug.WriteLine("Binding Notifications Suspended: " & Me.UltraDataSource1.BindingNotificationsSuspended)

            Dim row As UltraDataRow
            Dim column As UltraDataColumn
            For Each row In Me.UltraDataSource1.Rows
                For Each column In row.Band.Columns
                    row(column) = DBNull.Value
                Next
            Next
        Finally
            ' Resume ListChanged notifications.
            Me.UltraDataSource1.ResumeBindingNotifications()
        End Try
    End Sub
using Infragistics.Shared;
using Infragistics.Win;
using Infragistics.Win.UltraWinDataSource;
using Infragistics.Win.UltraWinGrid;
using System.Diagnostics;
		private void button1_Click(object sender, System.EventArgs e)
		{
			// SuspendBindingNotifications and ResumeBindingNotifications are used when
			// performing a large number of updates to the data. What it does is that it
			// prevents the UltraDataSource from firing ListChanged notifications on the
			// IBindingList implementation so any bound controls do not process the 
			// individual changes. When ResumeBindingNotifications is called, 
			// UltraDataSource will fire ListChanged with Reset as the type specifying
			// to the bound controls that they should reget the data for all rows. This
			// can be more efficient than firing notifications for individual changes
			// when there are lot of changes being made.
			//
			try
			{
				// Suspend IBindingList ListChanged notifications.
				this.ultraDataSource1.SuspendBindingNotifications( );

				// Value of BindingNotificationsSuspended property should be true after
				// calling SuspendBindingNotifications method.
				Debug.WriteLine( "Binding Notifications Suspended: " + this.ultraDataSource1.BindingNotificationsSuspended );

				foreach ( UltraDataRow row in this.ultraDataSource1.Rows )
				{
					foreach ( UltraDataColumn column in row.Band.Columns )
					{
						row[ column ] = DBNull.Value;
					}
				}
			}
			finally
			{
				// Resume ListChanged notifications.
				this.ultraDataSource1.ResumeBindingNotifications( );				
			}
		}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, 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

See Also