BackgroundTaskRegistration.Completed 事件
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
將已完成的事件處理常式附加至已註冊的背景工作。
public:
virtual event BackgroundTaskCompletedEventHandler ^ Completed;
// Register
event_token Completed(BackgroundTaskCompletedEventHandler const& handler) const;
// Revoke with event_token
void Completed(event_token const* cookie) const;
// Revoke with event_revoker
BackgroundTaskRegistration::Completed_revoker Completed(auto_revoke_t, BackgroundTaskCompletedEventHandler const& handler) const;
public event BackgroundTaskCompletedEventHandler Completed;
function onCompleted(eventArgs) { /* Your code */ }
backgroundTaskRegistration.addEventListener("completed", onCompleted);
backgroundTaskRegistration.removeEventListener("completed", onCompleted);
- or -
backgroundTaskRegistration.oncompleted = onCompleted;
Public Custom Event Completed As BackgroundTaskCompletedEventHandler Implements Completed