[CLOSED] Request Failure Error Status Code 200

  1. #1

    [CLOSED] Request Failure Error Status Code 200

    Hello,

    I am repeatedly getting Request Failure error (Status Code: 200) for the following code. What am I doing wrong?

    Note: Tree panel and nodes are created normally. After closing the request failure warning, there is no problem with rendering tree nodes.

    Thanks.

    <%@ Page Language="C#" %>
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
        <script runat="server">
            protected void Page_Load(object sender, EventArgs e)
            {
                if (!X.IsAjaxRequest)
                {
                    BuildMenuForUser();
                }
            }
            protected void BuildMenuForUser()
            {
                Ext.Net.TreePanel menuTreePanel = new Ext.Net.TreePanel();
                menuTreePanel.ID = "MenuTree";
                menuTreePanel.RootVisible = false;
    
                Ext.Net.Node menuRoot = new Ext.Net.Node();
                menuRoot.NodeID = "MenuRoot";
                menuRoot.Leaf = false;
                menuTreePanel.SetRootNode(menuRoot);
    
                Ext.Net.Node settingsNode = new Ext.Net.Node();
                settingsNode.Text = "Settings";
                settingsNode.Leaf = false;
                settingsNode.NodeID = "SettingsNode";
                menuTreePanel.GetRootNode().AppendChild(settingsNode);
    
                Ext.Net.Node setting1Node = new Ext.Net.Node();
                setting1Node.Text = "Setting 01";
                setting1Node.Leaf = true;
                menuTreePanel.GetNodeById("SettingsNode").AppendChild(setting1Node);
    
                menuTreePanel.AddTo(MainMenuPanel);
            }        
        </script>
    <!DOCTYPE html>
    <html>
    <head id="Head1" runat="server">
        <title>Ext.NET Examples</title>
    </head>
    <body>
        <form id="form1" runat="server">
        <ext:ResourceManager ID="ResourceManager1" runat="server"/>
        <div>
        <ext:Viewport ID="VP" runat="server" Layout="BorderLayout">
            <Items>
                <ext:Panel Title="Menu"
                            ID="MainMenuPanel"
                            runat="server"
                            Region="West"
                            Layout="AccordionLayout"
                            Collapsible="true"
                            Split="true"
                            Width="200"
                            MinWidth="200" 
                            MaxWidth="400">
                </ext:Panel>
                <ext:TabPanel Title="Center" 
                            ID="CenterPanel" 
                            runat="server" 
                            Region="Center" 
                            Layout="FitLayout"
                            AutoScroll="true">
                </ext:TabPanel>
            </Items>
        </ext:Viewport>
        </div>
        </form>
    </body>
    </html>
    Click image for larger version. 

Name:	requestfailure.png 
Views:	227 
Size:	15.8 KB 
ID:	5660
    Last edited by Baidaly; Feb 19, 2013 at 11:57 PM. Reason: [CLOSED]
  2. #2
    Hello,

    Try replacing this line:

    // menuTreePanel.AddTo(MainMenuPanel);
    MainMenuPanel.Items.Add(menuTreePanel);
    Hope this helps.
    Geoffrey McGill
    Founder
  3. #3
    Hello Geoffrey,

    I tried your suggestion, still no change.
  4. #4
    Here's a full simplified sample.

    Example

    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
     
        <script runat="server">
            protected void Page_Load(object sender, EventArgs e)
            {
                if (!X.IsAjaxRequest)
                {
                    this.BuildMenu();
                }
            }
    
    
            protected void BuildMenu()
            {
                TreePanel tree = new TreePanel();
                tree.ID = "MenuTree";
                tree.RootVisible = false;
     
                Node root = new Node();
                root.NodeID = "MenuRoot";
                root.Leaf = false;
                root.Expanded = false;
    
    
                tree.Root.Add(root);
                //tree.SetRootNode(root);
     
                Node node1 = new Node();
                node1.Text = "Settings";
                node1.Leaf = false;
                node1.NodeID = "SettingsNode";
    
    
                root.Children.Add(node1);
                //tree.GetRootNode().AppendChild(node1);
     
                Node node1_1 = new Node();
                node1_1.Text = "Setting 01";
                node1_1.Leaf = true;
    
    
                node1.Children.Add(node1_1);
                //tree.GetNodeById("SettingsNode").AppendChild(node1_1);
    
    
                //tree.AddTo(MainMenuPanel);
                this.Panel1.Items.Add(tree);
            }        
        </script>
    <!DOCTYPE html>
    <html>
    <head runat="server">
        <title>Ext.NET Examples</title>
    </head>
    <body>
        <form runat="server">
        <ext:ResourceManager runat="server"/>
    
    
        <ext:Viewport runat="server" Layout="BorderLayout">
            <Items>
                <ext:Panel 
                    ID="Panel1"
                    Title="Menu"
                    runat="server"
                    Region="West"
                    Layout="AccordionLayout"
                    Collapsible="true"
                    Split="true"
                    Width="200"
                    MinWidth="200"
                    MaxWidth="400"
                    />
                <ext:TabPanel 
                    Title="Center"
                    runat="server"
                    Region="Center"
                    />
            </Items>
        </ext:Viewport>
        </form>
    </body>
    </html>
    Hope this helps.
    Geoffrey McGill
    Founder
  5. #5
    The error went away (;
    Thank you Geoffrey, mark as closed please.
  6. #6
    i have same problem and i cant Resolve it
    can you say how resolved this problam?
    Last edited by somaye; Nov 26, 2013 at 8:31 PM.
  7. #7
    Hi @somaye,

    Welcome to the Ext.NET forums!

    Quote Originally Posted by somaye View Post
    i have same problam and i cant Resolve it
    can you say how resolved this problam?
    There is a bunch of possible reasons to a "Request Failure" error message. It would be better to start a new forum thread with a test case to reproduce. If you feel the threads are related, please feel free to cross-link between the two.
  8. #8
    hi Daniil
    thanks for your Replay
    ok but i dont know how can i start a new thread, Although the my Problem Exactly is same with this thread
    Last edited by somaye; Nov 26, 2013 at 8:31 PM.
  9. #9
    Quote Originally Posted by somaye View Post
    hi Daniil
    tanks for your Replay
    ok but i dont know how can i start a new thread, Although the my Problam Exactly is same with this thread
    Click the following link, the click on the "Post New Thread" button:

    http://forums.ext.net/forumdisplay.php?18-2-x-Help
    Geoffrey McGill
    Founder
  10. #10
    geoffrey.mcgill
    thanks for your Guidances

Similar Threads

  1. Request failure error
    By Vaishali in forum 1.x Help
    Replies: 0
    Last Post: May 09, 2012, 5:23 AM
  2. Request failure : Internal Server Error
    By richard in forum 2.x Help
    Replies: 1
    Last Post: Mar 15, 2012, 12:16 PM
  3. Replies: 16
    Last Post: Oct 04, 2011, 5:17 PM
  4. [CLOSED] Request Failure Error
    By speedstepmem3 in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Jun 22, 2009, 7:11 AM
  5. Replies: 2
    Last Post: Nov 26, 2008, 12:17 PM

Posting Permissions