DataPackagePropertySet.Description | description property

Applies to Windows and Windows Phone

Gets or sets text that describes the contents of the DataPackage.

Syntax


var description = dataPackagePropertySet.description;
dataPackagePropertySet.description = description;

Property value

Type: String [JavaScript] | System.String [.NET] | Platform::String [C++]

Text that describes the contents of the DataPackage.

Remarks

We recommend adding a description to a DataPackage object if you can. Target apps can use this description to help users identify what content they're sharing.

Examples

The following example shows how you can set the description for the content in a DataPackage.


function registerForShare() {
    var dataTransferManager = Windows.ApplicationModel.DataTransfer.DataTransferManager.getForCurrentView();
    dataTransferManager.addEventListener("datarequested", shareTextHandler);
}

function shareTextHandler(e) {
    var request = e.request;
    request.data.properties.title = "Share Text Example";
    request.data.properties.description = "A demonstration that shows how to share.";
    request.data.setText("Hello World!");
}


Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8

Namespace

Windows.ApplicationModel.DataTransfer
Windows::ApplicationModel::DataTransfer [C++]

Metadata

Windows.winmd

See also

DataPackagePropertySet

 

 

Show:
© 2014 Microsoft