Uredi

Deli z drugimi prek


WebPartCancelEventHandler Delegate

Definition

Represents the method that will handle the SelectedWebPartChanging event, WebPartClosing event, or WebPartDeleting event of the WebPartManager class.

public delegate void WebPartCancelEventHandler(System::Object ^ sender, WebPartCancelEventArgs ^ e);
public delegate void WebPartCancelEventHandler(object sender, WebPartCancelEventArgs e);
type WebPartCancelEventHandler = delegate of obj * WebPartCancelEventArgs -> unit
Public Delegate Sub WebPartCancelEventHandler(sender As Object, e As WebPartCancelEventArgs)

Parameters

sender
Object

The source of the event.

e
WebPartCancelEventArgs

A WebPartCancelEventArgs that contains the event data.

Remarks

The method specified in the WebPartCancelEventHandler delegate is called when a SelectedWebPartChanging event, WebPartClosing event, or WebPartDeleting event is raised.

Page developers can provide custom handlers for Web Parts events by adding an OnSelectedWebPartChanging attribute, OnWebPartClosing attribute, or OnWebPartDeleting attribute to the <asp:webpartmanager> element in a page, and assigning a custom method name to the attribute. A custom handler can also be assigned programmatically. For more information about how to subscribe to an event, see How to: Raise and Consume Events.

Extension Methods

GetMethodInfo(Delegate)

Gets an object that represents the method represented by the specified delegate.

Applies to