ToastNotification.Failed 이벤트

정의

Windows에서 알림 메시지를 표시하려고 할 때 오류가 발생할 때 발생합니다. 실행 중인 앱은 이 이벤트를 구독합니다.

// Register
event_token Failed(TypedEventHandler<ToastNotification, ToastFailedEventArgs const&> const& handler) const;

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

// Revoke with event_revoker
ToastNotification::Failed_revoker Failed(auto_revoke_t, TypedEventHandler<ToastNotification, ToastFailedEventArgs const&> const& handler) const;
public event TypedEventHandler<ToastNotification,ToastFailedEventArgs> Failed;
function onFailed(eventArgs) { /* Your code */ }
toastNotification.addEventListener("failed", onFailed);
toastNotification.removeEventListener("failed", onFailed);
- or -
toastNotification.onfailed = onFailed;
Public Custom Event Failed As TypedEventHandler(Of ToastNotification, ToastFailedEventArgs) 

이벤트 유형

설명

알림 실패의 원인은 ToastFailedEventArgs 매개 변수의 ErrorCode 속성에서 찾을 수 있습니다.

알림 메시지를 표시할 때 표시되는 가장 일반적인 오류는 이 사용자에 대한 알림 메시지 차단을 instance 설정 오류입니다. 이 이벤트를 통해 해당 상황을 처리하는 대신 Show를 호출하기 전에 ToastNotifier.Setting을 호출하는 것이 좋습니다.

적용 대상

추가 정보