I wondered if it was possible to use a virtual treeview, like in a gridview. There the option VirtualMode indicates that you implement you own data management routines, rather than adding items once... I expect to have a tree view with a lot of items, but I don't want them to be loaded at once (for performance reasons).
Does anyone have and idea?
5 Answers, 1 is accepted
You can use the Load-On-Demand mode of RadTreeView control for this behavior. More information about this feature you can find in our online documentation. In Q1 2011 SP1 release, planned for this week we will include full lazy mode support and performance improvements for the Load-On-Demand scenarios.Best wishes,
the Telerik team
Thanks for your answer; only now I found some time to work on this issue.
Another question arises now; When i have the root nodes loaded, but there are more nodes than fit in the visible area of the treeview, the scrollbar is not automatically shown. I've tried setting the AutoScroll option to true, but that doesn't help.
Do you have any ideas how to solve that?
Please accept my apologies for the delayed answer.
We found an issue in this scenario. I logged the issue in our Public Issue Tracking System. The fix will be available in one of the next releases. Currently, you can add this code line at the end in your Form Load event handler to update the layout:
I hope this helps.
Best wishes,Julian Benkov
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Since we have a growing list of root nodes in the tree view I was wondering if you have plans to implement a true virtualised version of the treeview, that only loads the visible root nodes to the treeview and requests for more items when scrolling down the treeview. We really need this since we're having serious performance issues with the treeview now. One of our customers is adding items to a database on a daily basis (approx 150 items per day) and have currently a list of 500K items to be shown in the tree. This is hardly workable and will become worse if we don't change the system.
Can you please advise on how to address this issue?
Thank you for contacting us.
Similar to RadGridView, RadTreeView is virtualized as well. Its visual nodes (TreeNodeElement) are reused by the data nodes (RadTreeNode), which bring increased performance and optimized memory footprint. Although, the initial adding of a great number of RadTreeNodes takes some adequate time, scrolling operation is performed without any performance issues.
The Load On Demand feature helps reduce performance and memory costs incurred when all nodes are loaded at once. To benefit from this feature, you can have a look at our Load On Demand help article, which Julian had already recommended. If it is not applicable for your specific case, a sample project would be highly appreciated, which demonstrates the serious performance issue that you are experiencing. Thus, we would be able to investigate the specific case and suggest an appropriate solution. Thank you for the co-operation.
Should you have further questions, I would be glad to help.