_Type.GetEvents Method (BindingFlags)


Provides COM objects with version-independent access to the Type.GetEvents method.

Namespace:   System.Runtime.InteropServices
Assembly:  mscorlib (in mscorlib.dll)

Function GetEvents (
	bindingAttr As BindingFlags
) As EventInfo()


Type: System.Reflection.BindingFlags

A bitmask comprised of one or more BindingFlags that specify how the search is conducted.


Zero, to return null.

Return Value

Type: System.Reflection.EventInfo()

An array of EventInfo objects representing all events that are declared or inherited by the current Type that match the specified binding constraints.


An empty array of type EventInfo, if the current Type does not have events, or if none of the events match the binding constraints.

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

The Type.GetEvents method searches for events that are declared or inherited by the current Type, using the specified binding constraints.

.NET Framework
Available since 1.1
Return to top