ResourceDictionary.Insert(Object, Object) Method

Definition

Adds a new entry to the ResourceDictionary.

Equivalent WinUI method: Microsoft.UI.Xaml.ResourceDictionary.Insert.

public:
 virtual bool Insert(Platform::Object ^ key, Platform::Object ^ value) = IMap<Platform::Object ^, Platform::Object ^>::Insert;
bool Insert(IInspectable const & key, IInspectable const & value);
public bool Insert(object key, object value);
function insert(key, value)
Public Function Insert (key As Object, value As Object) As Boolean

Parameters

key
Object

The object key for the resource to insert.

value
Object

The object value for the resource to insert.

Returns

Boolean

true if calling the method replaced a value that already existed for the key; false if calling the method defined a new key.

Implements

Remarks

Note

The equivalent Microsoft .NET API is Add.

Applies to

See also