This is a migrated thread and some comments may be shown as answers.

RadTreeView CheckChildNodes performance problem

1 Answer 145 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Glyn
Top achievements
Rank 1
Glyn asked on 15 Apr 2009, 01:37 AM
I'm using the RadTreeView to display hierarchical address information for users to select region coverage (e.g. Counrty-> State -> City -> Suburb) I have used TriState checkboxes and CheckChildNodes properties to enable a user to select a city and have all suburbs selected, but if the user then de-selectes a suburb - the triState checkbox of the city is set to indeterminate.

All good so far.

The total number of nodes we are dealing with in the current scenario is about 1800. A resonable, but not uncommon number.

The problem I'm having is when you are checking/unchecking parent nodes with a lot of child nodes (e.g at State/Country level) then the CheckChildNodes process (coupled with the TristateCheckBox) can take many seconds to run (e.g.10 -20 seconds or more). This is clearly more than an acceptable 1-2 seconds.

I don't think I can use the load on demand scenarios effectively because this will affect the use of the TristateCheckboxes. I.e.  If you haven't loaded all the ChildNodes how do you know if one is selected/unselected.

I have tried all sorts of different things to get this to perform better. Custom javascript to check the child nodes (no real improvement as expected) , posting back and doing the check/uncheck server-side (surprising quick without TriState enabled, dog slow with it enabled). Various combinations of events and properties. I have tried not using TriState which improves things slightly (but provides and inferior user experience), but the bulk of the problems seem to be in the CheckChildNodes.

Most of the performance related stuff on TreeView is around load-on-demand. Is there anything else I can do to speed this up?

1 Answer, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 15 Apr 2009, 01:59 PM
Hello Glyn,

Indeed there was a performance bottleneck in our checking code. Please download tomorrow's internal build (the build number should be 2008.1.415 or above). We have applied a few optimizations which should improve the performance.

Regards,
Albert
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
TreeView
Asked by
Glyn
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Share this question
or