Table of Contents

Method LoadExistingEx

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

LoadExistingEx(Stream, object, Flags, string?)

Populates an existing root object with the object property values created from a source XAML.

public static object LoadExistingEx(Stream xamlStream, object existingObject, UixmlLoader.Flags flags = (UixmlLoader.Flags)0, string? resName = null)

Parameters

xamlStream Stream
existingObject object
flags UixmlLoader.Flags
resName string

Returns

object

LoadExistingEx(string, object, Flags, string?)

Loads XAML markup into an existing object, updating its properties and state according to the provided XAML definition.

public static object LoadExistingEx(string xaml, object existingObject, UixmlLoader.Flags flags = (UixmlLoader.Flags)0, string? resName = null)

Parameters

xaml string

The XAML markup string that defines the properties and structure to apply to the existing object. Cannot be null.

existingObject object

The object instance to be updated with values from the XAML markup. Cannot be null.

flags UixmlLoader.Flags

Optional flags that control aspects of the loading behavior. The default is 0.

resName string

An optional resource name used for reporting load exceptions. May be null.

Returns

object

The existing object after it has been updated with the values from the XAML markup.

Remarks

If an exception occurs during the loading process, it is reported using the DefaultReportLoadException method. The method always returns the existing object, even if an error occurs.