Change Theme Settings
Change Theme Settings
Themes
 
Show All Themes
v
...v

Data Binding to XML

 Page Title
CollapseGeneral Information
 ExpandNews
 ExpandAbout Us
CollapseClient Services
 ExpandBuy and Download
 ExpandGet Support
CollapseOur Products
 ExpandSubscriptions / Packs
 Expand.NET Windows Forms
 ExpandASP.NET Products
 ExpandVCL Product Line
 ExpandIDE Productivity Tools
 ExpandBusiness App Frameworks
 ExpandActiveX Product Line


This demo illustrates how the BindToXML method can be used to populate the TreeList with node information taken from an XML file. The source XML file contains hierarchical information about a set of website pages.

The MVC TreeList can be bound to an XML file with the following data binding methods:

  • BindToXML(string fileName);
  • BindToXML(string fileName, string xPath);
  • BindToXML(string fileName, string xPath, string transformFileName);

In this demo, a column is added to the tree list. This column FieldName property value defines a name of the corresponding data source field.

Collapse/Expand
Local Copy of this Demo
To inspect the source code for this demo on your machine, you must first install our components via the DevExpress Component Installer.
You can open a local copy of this online demo directly from this webpage (if using v20.2.8, 21.1.4 or higher).
Open CS Solution
The source code files for this demo are installed (by default) in the following directory:
\Users\Public\Documents\DevExpress Demos XX.X\Components\ASP.NET\CS\MVCxTreeListDemos