PushNotificationReceivedEventArgs Classe

Definizione

Fornisce dati per l'evento PushReceived .

public ref class PushNotificationReceivedEventArgs sealed
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.Windows.PushNotifications.PushNotificationsContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class PushNotificationReceivedEventArgs final
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.Windows.PushNotifications.PushNotificationsContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class PushNotificationReceivedEventArgs
Public NotInheritable Class PushNotificationReceivedEventArgs
Ereditarietà
Object Platform::Object IInspectable PushNotificationReceivedEventArgs
Attributi

Commenti

Per assicurarsi che il gestore eventi PushReceived 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à generata l'eccezione di runtime seguente:

System.Runtime.InteropServices.COMException: 'Element not found. Must register event handlers before calling Register().'

Proprietà

Nome Descrizione
Payload

Ottiene il payload della notifica push che ha attivato l'evento PushReceived associato.

Metodi

Nome Descrizione
GetDeferral()

Informa il sistema che l'app potrebbe continuare a eseguire il lavoro dopo la restituzione del gestore eventi PushReceived .

Eventi

Nome Descrizione
Canceled

Generato quando il sistema annulla l'attività in background avviata per gestire l'evento PushReceived .

Si applica a