LayoutControl.LayoutUri Property

Gets or sets a uniform resource identifier (URI) of the layout to be loaded. This is a dependency property.

Namespace: DevExpress.Xpf.LayoutControl

Assembly: DevExpress.Xpf.LayoutControl.v20.1.dll

Declaration

public Uri LayoutUri { get; set; }
Public Property LayoutUri As Uri

Property Value

Type Description
Uri

A Uri object that specifies a path to the layout to be loaded.

Remarks

It's possible to store a layout of items of a LayoutControl object in XML format to a file, and then load the saved layout by specifying the URI of the file via the LayoutUri property. Once a new value is assigned to the LayoutUri property, the LayoutControl automatically loads the layout.

Assume that a layout has been saved to file "Layout.xaml" and then added to the application project. To load this layout, you can use the following code:

<lc:LayoutControl x:Name="myLayoutControl" LayoutUri="Layout.xaml">

The LayoutControl's LayoutControlBase.WriteToXML method allows you to save the layout of items to a data store. To restore the layout, you can use the LayoutControl.ReadFromXML method.

See Also