radtreeview with checkboxes inside radwindow

3 posts, 0 answers
  1. mirang
    mirang avatar
    115 posts
    Member since:
    Aug 2010

    Posted 17 Feb 2012 Link to this post

    I have a radtreeview inside a radwindow. My requirement is there there can be 10000-15000 nodes expanded from where the user can select a node. The window opens as a modal window on top of an existing page. There are two issues observed only in IE : 
    1. when say around 10000 nodes are expanded and user checks on any node, the radwindow goes blank and slowly renders itself.
    2. when the user closes the radwindow with this many nodes(10000), the window takes 2-3 seconds just to get closed.
    For the rest of the browsers like chrome and firefox this is not the case.
    Is this a known limitation of IE ? 
  2. Marin Bratanov
    Marin Bratanov avatar
    5936 posts

    Posted 20 Feb 2012 Link to this post

    Hi Mirang,

    By having 15000 nodes the sheer amount of HTML that needs to be rendered could trouble slower browsers like IE (especially it older versions). This is even without taking into account all the necessary JavaSctipt and event handlers that need to be attached for the controls to function. This means that this is a general issue with the browser's ability to handle such a huge page. The best approach here is to reduce the page size, as it will 1) yield better performance and 2) provide better usability.

    On clicking a node - you should first check if you perform a postback or an AJAX request, as this is a viable reason for the browser to re-render the page. Especially in the case of AJAX the markup is recreated via JavaScript which is much slower than the normal rendering of the browser. Also, please examine your other event handlers for the treeview, as it may need to refresh its state once you click a node. This may be unavoidable depending on your needs. The fact that you see it is again because of the enormity of the needed data - each DOM object used via JavaScript takes up a lot of memory for starters.

     The slow closing is again most likely related to the general slowness of the page - what it does is to hide the RadWindow (and its content) by changing CSS properties via JavaScript. If you are using the NavigateUrl to load an external page you can use the OnClientClose event of the RadWindow to change its URL to about:blank (i.e. sender.setUrl("about:blank"); where sender is the first argument the event handler receives) to reload the iframe and relieve the browser of so many nodes.

    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. mirang
    mirang avatar
    115 posts
    Member since:
    Aug 2010

    Posted 20 Feb 2012 Link to this post

    Thanks for the reply.

    As a workaround, I handled the onbeforeclose event on the page which is opened in the radwindow and disposed the treeview by calling treeview.get_nodes().clear() this solved my problem, of fast closing the radwindow. 
Back to Top