Show Loading Message while RadTreeView is being loaded

1 posts, 0 answers
  1. Telerik Admin
    Telerik Admin avatar
    1679 posts
    Member since:
    Oct 2004

    Posted 17 Jul 2007 Link to this post


    Requirements

    RadControls version

    RadTreeView v6.x
    RadTreeView AJAX (Prometheus)
    Telerik.Web.UI 2007.3.1245
    .NET version

    2.0     
    Visual Studio version

    2005
    programming language

    C#
    browser support

    all browsers supported by RadControls


     
    PROJECT DESCRIPTION
    This project shows how you can show a loading message while a large treeview data is being loaded on the page. Thus, the users will be aware that something is happening. This sample project does not use any ajax but a simple javascript approach:




    <script type="text/javascript">                  
    function pageLoad()   
    {   
        var treeDIV = document.getElementById("treeDIV");   
        treeDIV.style.visibility = "visible";   
           
        var loadDIV = document.getElementById("loadDIV");   
        loadDIV.style.visibility = "hidden";   
    }   
    </script>  
    <div id="loadDIV">   
        Loading Message       
     </div>   
    <div id="treeDIV" style="visibility:hidden">   
        <telerik:RadTreeView ID="RadTreeView1" runat="server"
        </telerik:RadTreeView> 
    </div> 




    <div id="loadDIV"
            Loading Message      
         </div> 
        <div id="treeDIV" style="visibility:hidden"
         <radT:RadTreeView 
               ID="RadTree1" 
               Runat="server" ... /> 
    <script type="text/javascript">                
        window.onload = function() 
        { 
            var treeDIV = document.getElementById("treeDIV"); 
            treeDIV.style.visibility = "visible"
            
            var loadDIV = document.getElementById("loadDIV"); 
            loadDIV.style.visibility = "hidden"
        } 
    </script> 

Back to Top