Share via


AccountsSettingsPane.AccountCommandsRequested 事件

定義

發生于使用者開啟帳戶窗格時。 處理此事件可讓應用程式初始化帳戶命令,並暫停其 UI,直到使用者關閉窗格為止。

// Register
event_token AccountCommandsRequested(TypedEventHandler<AccountsSettingsPane, AccountsSettingsPaneCommandsRequestedEventArgs const&> const& handler) const;

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

// Revoke with event_revoker
AccountsSettingsPane::AccountCommandsRequested_revoker AccountCommandsRequested(auto_revoke_t, TypedEventHandler<AccountsSettingsPane, AccountsSettingsPaneCommandsRequestedEventArgs const&> const& handler) const;
public event TypedEventHandler<AccountsSettingsPane,AccountsSettingsPaneCommandsRequestedEventArgs> AccountCommandsRequested;
function onAccountCommandsRequested(eventArgs) { /* Your code */ }
accountsSettingsPane.addEventListener("accountcommandsrequested", onAccountCommandsRequested);
accountsSettingsPane.removeEventListener("accountcommandsrequested", onAccountCommandsRequested);
- or -
accountsSettingsPane.onaccountcommandsrequested = onAccountCommandsRequested;
Public Custom Event AccountCommandsRequested As TypedEventHandler(Of AccountsSettingsPane, AccountsSettingsPaneCommandsRequestedEventArgs) 

事件類型

備註

當您的應用程式處理此事件時,請將提供的 AccountsSettingsPaneCommandsRequestedEventArgs 填入 您的 SettingsCommand 物件、 您的 CredentialCommand 物件和 WebAccountCommand 物件,使其可供 AccountsSettingsPaneUI 使用。

如果修改窗格時發生錯誤,呼叫 Show 將會以無訊息方式失敗,而且不會顯示窗格。

適用於