BackgroundTaskCanceledEventHandler Delegato

Definizione

Rappresenta un metodo che gestisce l'annullamento di un'attività in background.

public delegate void BackgroundTaskCanceledEventHandler(IBackgroundTaskInstance ^ sender, BackgroundTaskCancellationReason reason);
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.Guid(2797910720, 20984, 19543, 172, 63, 21, 109, 209, 104, 12, 79)]
class BackgroundTaskCanceledEventHandler : MulticastDelegate
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.Guid(2797910720, 20984, 19543, 172, 63, 21, 109, 209, 104, 12, 79)]
public delegate void BackgroundTaskCanceledEventHandler(IBackgroundTaskInstance sender, BackgroundTaskCancellationReason reason);
var backgroundTaskCanceledEventHandlerHandler = function(sender, reason){
/* Your code */
}
Public Delegate Sub BackgroundTaskCanceledEventHandler(sender As IBackgroundTaskInstance, reason As BackgroundTaskCancellationReason)

Parametri

sender
IBackgroundTaskInstance

Istanza dell'attività in background annullata.

reason
BackgroundTaskCancellationReason

Motivo per cui l'istanza dell'attività in background è stata annullata.

Attributi

Requisiti Windows

Famiglia di dispositivi
Windows 10 (è stato introdotto in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (è stato introdotto in v1.0)

Si applica a