WebPart.OnEditModeChanged(EventArgs) 方法

定义

启用派生类,以在 WebPart 控件进入或离开编辑模式时提供自定义处理。Enables derived classes to provide custom handling when a WebPart control is entering or leaving edit mode.

protected public:
 virtual void OnEditModeChanged(EventArgs ^ e);
protected internal virtual void OnEditModeChanged (EventArgs e);
abstract member OnEditModeChanged : EventArgs -> unit
override this.OnEditModeChanged : EventArgs -> unit
Protected Friend Overridable Sub OnEditModeChanged (e As EventArgs)

参数

e
EventArgs

包含事件数据的 EventArgsAn EventArgs that contains the event data.

注解

WebPart 基类中的方法不包含实现。The method in the WebPart base class contains no implementation.

继承者说明

派生控件需要重写 OnEditModeChanged(EventArgs) 方法,并使用重写的方法引发自定义事件。A derived control needs to override the OnEditModeChanged(EventArgs) method, and use the overridden method to raise a custom event. 开发人员可以引发自定义事件或执行其他操作。Developers can raise custom events or carry out other actions. 在编辑过程中调用 BeginWebPartEditing(WebPart)EndWebPartEditing() 方法时,将调用方法。The method is called when the BeginWebPartEditing(WebPart) and EndWebPartEditing() methods are called during editing.

适用于

另请参阅