refresh cause tree panel blank

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1

    refresh cause tree panel blank

    Greeting ....

    I use this code to refresh my tree ..

    <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Barang.aspx.cs" Inherits="WebApplication1.Setup.Barang" %>
    
    <script runat="server">
    
    [DirectMethod]
    public string RefreshMenu()
    {
        Ext.Net.NodeCollection nodes = this.BuildTree(null);
        return nodes.ToJson();
    }
      
    </script>
    
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
        <title></title>
        <script>
    
            var refreshTree = function (tree) {
                App.direct.RefreshMenu({
                    success: function (result) {
                        var nodes = eval(result);
                        if (nodes.length > 0) {
                            tree.setRootNode(nodes[0]);
                        }
                        else {
                            tree.getRootNode().removeAll();
                        }
                    }
                });
            };
    
        </script>
    </head>
    I get that code from Ext.Net example #/TreePanel/Basic/Refresh_Static_Tree/

    and build tree using Ext.Net example #/TreePanel/Loaders/Direct_Method/

    it look like

    Click image for larger version. 

Name:	treePanel_ada.png 
Views:	81 
Size:	82.8 KB 
ID:	25354

    but after refresh using that code above, my tree become like this

    Click image for larger version. 

Name:	treePanel_blank.png 
Views:	63 
Size:	25.9 KB 
ID:	25355

    is there any solution .... ???

    Thank's ....
    Last edited by fabricio.murta; May 29, 2020 at 3:53 PM. Reason: Add URLs to examples references.

Similar Threads

  1. Replies: 1
    Last Post: Nov 05, 2017, 11:22 AM
  2. [CLOSED] Refresh Tree Panel
    By S.KARATHANASIS in forum 2.x Legacy Premium Help
    Replies: 2
    Last Post: Sep 17, 2013, 2:04 PM
  3. Replies: 11
    Last Post: Oct 07, 2011, 9:14 AM
  4. Replies: 8
    Last Post: May 28, 2009, 8:18 PM
  5. Replies: 3
    Last Post: Jan 03, 2009, 10:41 PM

Posting Permissions