Returns the EventInfo object representing the specified public event.
using System;
using System.Reflection;
using System.Security;
class MyEventExample
{
publicstaticvoid Main()
{
Type myType = typeof(System.Windows.Forms.Button);
EventInfo myEvent = myType.GetEvent("Click");
if(myEvent != null)
{
Console.WriteLine("Looking for the Click event in the Button class.");
Console.WriteLine(myEvent.ToString());
}
}
}