Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

DataPackagePropertySetView class

Applies to Windows and Windows Phone

Gets the set of properties of a DataPackageView object.

Syntax


var dataPackagePropertySetView = dataPackageView.properties;

Attributes

[DualApiPartition()]
[MarshalingBehavior(Agile)]
[Version(0x06020000)]

Members

The DataPackagePropertySetView class has these types of members:

Methods

The DataPackagePropertySetView class has these methods. With C#, Visual Basic, and C++, it also inherits methods from the Object class.

MethodDescription
ContainsKey [C#, VB]Returns a value that indicates whether a specified key exists in the DataPackagePropertySetView.
First [C++, JavaScript]Returns an iterator to enumerate the items in the property set.
HasKey [C++, JavaScript]Indicates whether the DataPackagePropertySetView object contains a specific property.
Lookup [C++, JavaScript]Retrieves the value of a specific property.
Split [C++, JavaScript]Divides the object into two views
TryGetValue [C#, VB]Returns a value that indicates whether a specified key exists in the DataPackagePropertySetView. If an item with that key exists, the item is retrieved as an out parameter.

 

Properties

The DataPackagePropertySetView class has these properties.

PropertyAccess typeDescription

ApplicationListingUri

Read-onlyGets the Uniform Resource Identifier (URI) of the app's location in the Windows Store.

ApplicationName

Read-onlyGets the name of the app that created the DataPackage object.

ContentSourceApplicationLink

Read-onlyGets the application link to the content from the source app.

ContentSourceWebLink

Read-onlyGets a web link to shared content that's currently displayed in the app.

Count [C#, VB]

Read-onlyGets the number of elements contained in the collection.

Description

Read-onlyGets the text that describes the contents of the DataPackage.

FileTypes

Read-onlyGets a vector object that contains the types of files stored in the DataPackage object.

Item [C#, VB]

Read-onlyGets or sets the element value at the specified key index.

Keys [C#, VB]

Read-onlyGets an enumerable set containing the keys of the DataPackagePropertySetView.

LogoBackgroundColor

Read-onlyGets a background color for the sharing app's Square30x30Logo.

PackageFamilyName

Read-onlyGets the package family name of the source app.

Size [C++, JavaScript]

Read-onlyGets the number of items that are contained in the property set.

Square30x30Logo

Read-onlyGets the source app's logo.

Thumbnail

Read-onlyGets the thumbnail image for the DataPackageView.

Title

Read-onlyGets the text that displays as a title for the contents of the DataPackagePropertySetView object.

Values [C#, VB]

Read-onlyGets an enumerable set containing the values of the DataPackagePropertySetView.

 

Remarks

In addition to the content being shared, each instance of a DataPackageView object supports a set of properties. Target apps can use these properties to learn more about the content of the DataPackageView.

This class directly supports several default properties, such as a thumbnail, a title, and a description. Target apps can access specific properties through the Lookup or TryGetValue methods.

  • Applies to Windows Phone

Note  

When a share target receives shared content, it also receives certain properties associated with the source app as a part of the DataPackageView. In Windows Runtime apps, several of these properties, such as ApplicationListingUri, ApplicationName, and PackageFamilyName, will be set by the operating system. In Windows Phone Silverlight apps, however, these properties will not be automatically filled and must be set manually.

Collection member lists

For JavaScript, DataPackagePropertySetView supports using an index to access items.

Examples


if (shareOperation.data.contains(Windows.ApplicationModel.DataTransfer.StandardDataFormats.text)) {
    var title = shareOperation.data.properties.title;
    var description = shareOperation.data.properties.description;
}


Requirements

Minimum supported client

Windows 8 [Windows Store apps, desktop apps]

Minimum supported server

Windows Server 2012 [Windows Store apps, desktop apps]

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

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

Metadata

Windows.winmd

 

 

Show:
© 2014 Microsoft