AppNotificationManager.NotificationInvoked Evento

Definizione

Generato quando viene richiamata una notifica dell'app per l'app tramite l'interazione dell'utente.

Nota

La classe AppNotificationManager ha una dipendenza dal pacchetto Singleton. A causa di tale dipendenza, esistono alcune considerazioni da tenere presente se si chiamano queste API da un'app autonoma. Per altre informazioni e specifiche, vedere Dipendenze su pacchetti MSIX aggiuntivi.

// Register
event_token NotificationInvoked(TypedEventHandler<AppNotificationManager, AppNotificationActivatedEventArgs const&> const& handler) const;

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

// Revoke with event_revoker
AppNotificationManager::NotificationInvoked_revoker NotificationInvoked(auto_revoke_t, TypedEventHandler<AppNotificationManager, AppNotificationActivatedEventArgs const&> const& handler) const;
public event TypedEventHandler<AppNotificationManager,AppNotificationActivatedEventArgs> NotificationInvoked;
function onNotificationInvoked(eventArgs) { /* Your code */ }
appNotificationManager.addEventListener("notificationinvoked", onNotificationInvoked);
appNotificationManager.removeEventListener("notificationinvoked", onNotificationInvoked);
- or -
appNotificationManager.onnotificationinvoked = onNotificationInvoked;
Public Custom Event NotificationInvoked As TypedEventHandler(Of AppNotificationManager, AppNotificationActivatedEventArgs) 

Tipo evento

Commenti

Per assicurarsi che il gestore eventi NotificationIn richiamato venga chiamato all'interno del processo dell'app in esecuzione, assicurarsi di registrare il gestore per questo evento prima di chiamare Register. In caso contrario, verrà avviato un nuovo processo per gestire la chiamata.

Si applica a

Vedi anche