This demo shows how Virtual Mode helps you improve tree view performance.
In addition to bound and unbound modes, the ASPxTreeView can operate in Virtual Mode, which greatly reduces both server load and start-up time when working with complex or dynamically created hierarchies. In Virtual Mode, data is retrieved on the server in portions, on a client request, at start-up and when expanding nodes. In essence, child nodes are created and initialized only when their parent node is expanded for the first time. This allows you to efficiently use server resources and to avoid retrieving the entire amount of hierarchical data for the ASPxTreeView.
To activate Virtual Mode for the ASPxTreeView, handle its VirtualModeCreateChildren event, which occurs when expanding nodes for the first time. Within the event handler, you need to create a list of TreeViewVirtualNode objects representing child nodes for the currently expanded node. If a child node has no children, set its IsLeaf property to true, to not show the expand button for this node.
In this demo, the ASPxTreeView uses Virtual Mode to display the file/folder tree of the demo's web site.