DataRequestDeferral DataRequestDeferral DataRequestDeferral DataRequestDeferral DataRequestDeferral Class


Enables you to exchange content with a target app asynchronously.

public : sealed class DataRequestDeferral : IDataRequestDeferral
struct winrt::Windows::ApplicationModel::DataTransfer::DataRequestDeferral : IDataRequestDeferral
public sealed class DataRequestDeferral : IDataRequestDeferral
Public NotInheritable Class DataRequestDeferral Implements IDataRequestDeferral
// This class does not provide a public constructor.
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)


This example shows how to get a DataRequestDeferral object as part of sharing an image with a target app.

void DataRequested(DataTransferManager sender, DataRequestedEventArgs e)
    DataRequestDeferral deferral = e.Request.GetDeferral();
    e.Request.Data.Properties.Title = "Hello World!";
    e.Request.Data.Properties.Description = "This example shows how to share files and images.";
    if (this.dataPackageThumbnail != null)
        e.Request.Data.Properties.Thumbnail = this.dataPackageThumbnail;
function registerForShare() {
    var dataTransferManager = Windows.ApplicationModel.DataTransfer.DataTransferManager.getForCurrentView();
    dataTransferManager.addEventListener("datarequested", shareImageHandler);

function shareImageHandler(e) {
    var request = e.request; = "Share Image Example"; = "A demonstration that shows how to share an image.";
    var deferral = request.getDeferral();
    Windows.ApplicationModel.Package.current.installedLocation.getFileAsync("images\\smalllogo.png").then(function (thumbnailFile) { = Windows.Storage.Streams.RandomAccessStreamReference.createFromFile(thumbnailFile);
        return Windows.ApplicationModel.Package.current.installedLocation.getFileAsync("images\\logo.png");
    }).done(function (imageFile) {;
    }, function (err) {


You get an instance of the DataRequestDeferral class when you call the getDeferral method of a DataPackage.


Complete() Complete() Complete() Complete() Complete()

Indicates that the content for an asynchronous share is ready for a target app, or that an error in the sharing operation occurred.