System.Runtime.InteropServices._EventInfo.GetAddMethod Method

Provides COM objects with version-independent access to the System.Reflection.EventInfo.GetAddMethod(bool) method.

Syntax

public System.Reflection.MethodInfo GetAddMethod (bool nonPublic)

Parameters

nonPublic
true to return non-public methods; otherwise, false.

Returns

A System.Reflection.MethodInfo object representing the method used to add an event-handler delegate to the event source.

Remarks

This method is for access to managed classes from unmanaged code and should not be called from managed code.

The System.Reflection.EventInfo.GetAddMethod(bool) method retrieves the System.Reflection.MethodInfo object for the System.Reflection.EventInfo.AddEventHandler(object, Delegate) method of the event and specifies whether to return non-public methods

Requirements

Namespace: System.Runtime.InteropServices
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0