共用方式為


LoggingChannel.LoggingEnabled 事件

定義

當記錄通道附加至 LoggingSession 或其他事件追蹤和偵錯工具時引發。

// Register
event_token LoggingEnabled(TypedEventHandler<ILoggingChannel, IInspectable const&> const& handler) const;

// Revoke with event_token
void LoggingEnabled(event_token const* cookie) const;

// Revoke with event_revoker
LoggingChannel::LoggingEnabled_revoker LoggingEnabled(auto_revoke_t, TypedEventHandler<ILoggingChannel, IInspectable const&> const& handler) const;
public event TypedEventHandler<ILoggingChannel,object> LoggingEnabled;
function onLoggingEnabled(eventArgs) { /* Your code */ }
loggingChannel.addEventListener("loggingenabled", onLoggingEnabled);
loggingChannel.removeEventListener("loggingenabled", onLoggingEnabled);
- or -
loggingChannel.onloggingenabled = onLoggingEnabled;
Public Custom Event LoggingEnabled As TypedEventHandler(Of ILoggingChannel, Object) Implements LoggingEnabled

事件類型

實作

備註

當應用程式進程內的會話或核心模式 ETW 會話開始使用偵錯或效能分析工具時,就會引發 LoggingEnabled 事件。

適用於

另請參閱