I’m in a situation where I need to display a tree. However some of the nodes have 35000 child nodes (direct childs!). This of course is way to slow in terms of usability.
I’d rather see that the tree loads only those nodes that are visible in the browser viewport.
Such trees exist for WinForms and C++, does any of you know if such a tree exist for ASP.NET?
We are currently using the Telerik Treeview, which is a lovely control, but does not support the situation described.
extra questions
From a usability point of view: how do you deal with such trees. Displaying 35000 nodes on one level is nice, but how do you find something in that tree? Do you use paging in a tree? or a search box? or maybe add extra levels?
With that many nodes, even if you can find a performant way to display them, it is likely not going to be very usable by your users. Imagine trying to scroll through 35,000 nodes just to find the node you’re interested in! Same goes for paging. Is an user really going to page 3500 pages (assuming a page size of 10) to find their target? Probably not, and if they do, they probably won’t be too happy. 🙂
Instead, with large data sets like this, I find it’s usually best to provide some type of “Filter” UI. Something that enables your user to “shape” the available data in to a more manageable collection.
I’m not sure what ability you have to provide filtering (i.e. what fields you might filter on), but I think that’s your best bet. Options for the UI are:
Clearly there are other approaches, too, but hopefully this gives you some ideas.
Short Answer: For large datasets, I’d use a combination of real-time filtering and web services to present a more manageable result set to my users. For initial load, I’d only load the first (let’s say) 200 nodes to keep performance high.
Hope this helps!
-Todd