TreeList.RestoreLayoutFromXml(String, OptionsLayoutBase) Method

Loads a control's layout from the specified XML file, using the specified options.

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v20.1.dll

Declaration

public virtual void RestoreLayoutFromXml(
    string xmlFile,
    OptionsLayoutBase options
)
Public Overridable Sub RestoreLayoutFromXml(
    xmlFile As String,
    options As OptionsLayoutBase
)

Parameters

Name Type Description
xmlFile String

A string value specifying the XML file from which control settings are read.

options OptionsLayoutBase

An OptionsLayoutTreeList object that specifies which Tree List options must be restored. Or, a OptionsLayoutBase.FullLayout object, to restore all the settings.

Remarks

Use the RestoreLayoutFromXml method to load the Tree List control's layout from an XML file. Control settings must have previously been written to this file via the TreeList.SaveLayoutToXml method call.

NOTE

When restoring a layout during a form load (for instance, in your Form.Load event handler), you may need to call the TreeList.ForceInitialize method prior to the layout restoration. See this method to learn more.

See Also