Επεξεργασία

Κοινή χρήση μέσω


DataChangedEventManager.AddHandler Method

Definition

Adds the specified event handler, which is called when specified source raises the CurrentChanging event.

public:
 static void AddHandler(System::Windows::Data::DataSourceProvider ^ source, EventHandler<EventArgs ^> ^ handler);
public static void AddHandler (System.Windows.Data.DataSourceProvider source, EventHandler<EventArgs> handler);
static member AddHandler : System.Windows.Data.DataSourceProvider * EventHandler<EventArgs> -> unit
Public Shared Sub AddHandler (source As DataSourceProvider, handler As EventHandler(Of EventArgs))

Parameters

source
DataSourceProvider

The source object that the raises the DataChanged event.

handler
EventHandler<EventArgs>

The delegate that handles the DataChanged event.

Exceptions

handler is null.

Remarks

Use this method to specify the event handler you want to use to subscribe to the DataChanged event. When you use this method, your listener object does not need to implement the IWeakEventListener interface.

Applies to