EventRoute.Add(Object, Delegate, Boolean) Method

Definition

Adds the specified handler for the specified target to the route.

C#
public void Add(object target, Delegate handler, bool handledEventsToo);

Parameters

target
Object

Specifies the target object of which the handler is to be added to the route.

handler
Delegate

Specifies the handler to be added to the route.

handledEventsToo
Boolean

Indicates whether or not the listener detects events that have already been handled.

Remarks

It is not an error to add a handler for a particular target instance twice. In such a case, the handler will be called twice.

Applies to

Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9