This demo shows how to bind the TreeList to a List object. Since the TreeList is designed to display information in a tree structure, its data source should meet certain requirements. Two additional fields are necessary to build a tree structure.
The first field must contain unique values. This field must be assigned to the KeyFieldName property. The second field must contain values that indicate parent nodes for the current node. It should be assigned to the ParentFieldName property. Columns bound to these fields are called Service columns.
In this demo, toggle the 'Show service columns' check box to display or hide service columns.
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
\Users\Public\Documents\DevExpress Demos XX.X\Components\ASP.NET\CS\MVCxTreeListDemos |