WindowEventsClass.WindowClosing 事件
更新:2007 年 11 月
這個 API 支援 .NET Framework 基礎結構,但您不可以直接在程式碼中使用它。
發生於視窗正要關閉之前。
命名空間: EnvDTE
組件: EnvDTE (在 EnvDTE.dll 中)
語法
Public Overridable Event WindowClosing As _dispWindowEvents_WindowClosingEventHandler
Dim instance As WindowEventsClass
Dim handler As _dispWindowEvents_WindowClosingEventHandler
AddHandler instance.WindowClosing, handler
public virtual event _dispWindowEvents_WindowClosingEventHandler WindowClosing
public:
virtual event _dispWindowEvents_WindowClosingEventHandler^ WindowClosing {
void add (_dispWindowEvents_WindowClosingEventHandler^ value);
void remove (_dispWindowEvents_WindowClosingEventHandler^ value);
}
JScript 不支援事件。
實作
_dispWindowEvents_Event.WindowClosing
範例
Public Sub WindowEvents_WindowClosing(ByVal Window As EnvDTE.Window) Handles WindowEvents.WindowClosing
MsgBox("test")
End Sub
使用權限
- 完全信任立即呼叫者。這個成員無法供部分信任的程式碼使用。如需詳細資訊,請參閱從部分受信任程式碼使用程式庫。