DataPackagePropertySet.Insert(String, Object) DataPackagePropertySet.Insert(String, Object) DataPackagePropertySet.Insert(String, Object) DataPackagePropertySet.Insert(String, Object) DataPackagePropertySet.Insert(String, Object) Method

Definition

Adds a property to the DataPackagePropertySet object.

public : Platform::Boolean Insert(Platform::String key, Platform::Object value)
bool Insert(winrt::hstring key, winrt::Windows::Foundation::IInspectable value) const;
public bool Insert(String key, Object value)
Public Function Insert(key As String, value As Object) As bool
var bool = dataPackagePropertySet.insert(key, value);

Parameters

key
String String String

The key to insert.

value
Object Object Object

The value to insert.

Returns

bool bool bool

True if the method replaced a value that already existed for the key; false if this is a new key.

Remarks

Use this method if your app needs to add a custom property to the DataPackagePropertySet object. A custom property is any property that you can't define by using an existing property of the object. For example, title is a property that the object supports directly, but if you wanted a subtitle property, you would need to use Insert to add it.

For more info, see IMapView(String, Object).