WebBaseEvent.Raise Method (WebBaseEvent)

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Raises the specified event by notifying any configured provider that the event has occurred.

Namespace:   System.Web.Management
Assembly:  System.Web (in System.Web.dll)

[AspNetHostingPermissionAttribute(SecurityAction.Demand, Level = AspNetHostingPermissionLevel.Medium)]
public static void Raise(
	WebBaseEvent eventRaised
)

Parameters

eventRaised
Type: System.Web.Management.WebBaseEvent

A WebBaseEvent object.

Exception Condition
HttpException

The EventCode property of eventRaised has a value that is reserved for ASP.NET.

This method raises the specified event by notifying any configured provider that the event has occurred.

System_CAPS_noteNote

Medium trust or higher is required to raise an event.

The following code example shows how to use the Raise method.


// Raises the SampleWebBaseEvent.
public void CustomRaise(
    System.Web.Management.WebBaseEvent evnt)
{

    // Raise the event.
    Raise(evnt);
}

.NET Framework
Available since 2.0
Return to top
Show: