バージョン

DataSourceEventManager クラス

UltraDataSourceのイベントを管理するクラス。各イベントのEnabledフラグとネストされた「処理中」カウントを保持し、各イベントを発生させるメソッドを公開します。
シンタックス
'宣言
 
Public Class DataSourceEventManager 
   Inherits Infragistics.Shared.EventManagerBase
public class DataSourceEventManager : Infragistics.Shared.EventManagerBase 
使用例
Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinDataSource


    Private Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim eventManager As DataSourceEventManager = Me.UltraDataSource1.EventManager

        ' You can disable an individual event from firing.
        Debug.WriteLine("InitializeDataRow enabled ? " & eventManager.IsEnabled(DataSourceEventIds.InitializeDataRow))
        eventManager.SetEnabled(DataSourceEventIds.InitializeDataRow, False)
        Debug.WriteLine("InitializeDataRow enabled ? " & eventManager.IsEnabled(DataSourceEventIds.InitializeDataRow))

        ' You can also disable a group of events from firing.
        Debug.WriteLine("After events enabled ? " & eventManager.IsEnabled(DataSourceEventGroups.AfterEvents))
        eventManager.SetEnabled(DataSourceEventGroups.AfterEvents, False)
        Debug.WriteLine("After events enabled ? " & eventManager.IsEnabled(DataSourceEventGroups.AfterEvents))
    End Sub
using Infragistics.Shared;
using Infragistics.Win;
using Infragistics.Win.UltraWinDataSource;
using System.Diagnostics;


		private void button1_Click(object sender, System.EventArgs e)
		{
			DataSourceEventManager eventManager = this.ultraDataSource1.EventManager;

			// You can disable an individual event from firing.
			Debug.WriteLine( "InitializeDataRow enabled ? " + eventManager.IsEnabled( DataSourceEventIds.InitializeDataRow ) );
			eventManager.SetEnabled( DataSourceEventIds.InitializeDataRow, false );
			Debug.WriteLine( "InitializeDataRow enabled ? " + eventManager.IsEnabled( DataSourceEventIds.InitializeDataRow ) );

			// You can also disable a group of events from firing.
			Debug.WriteLine( "After events enabled ? " + eventManager.IsEnabled( DataSourceEventGroups.AfterEvents ) );
			eventManager.SetEnabled( DataSourceEventGroups.AfterEvents, false );
			Debug.WriteLine( "After events enabled ? " + eventManager.IsEnabled( DataSourceEventGroups.AfterEvents ) );
		}
参照