Note that there are some explanatory texts on larger screens.

plurals
  1. POTelerik RadAjaxManager loads controls slow the first time
    primarykey
    data
    text
    <p>So I have a RadPanelBar, and within that a RadTreeView. On a node click event I want so update some control.. for now I am just trying to update a textbox. It works fine except that the first time I click on a child node it takes a very long time to update the control.. Just a simple text change. I set a break point in my function and I noticed that it is taking long to fire the OnNodeClick event.. If I click a parent node in the tree view it loads fine on the first click. Also, after the first time I've clicked it.. it loads quickly.. If I refresh the page, it is slow on the first click again.. Is there something I am missing.. Is the structure of my HTML inappropriate for these AJAX calls? I feel like this is a really simple example that should work..</p> <pre><code>&lt;asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent"&gt; &lt;telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"&gt; &lt;AjaxSettings&gt; &lt;telerik:AjaxSetting AjaxControlID="IncidentReportPanel"&gt; &lt;UpdatedControls&gt; &lt;telerik:AjaxUpdatedControl ControlID="IRViewPanel" LoadingPanelID="LoadingPanel1" /&gt; &lt;/UpdatedControls&gt; &lt;/telerik:AjaxSetting&gt; &lt;/AjaxSettings&gt; &lt;/telerik:RadAjaxManagerProxy&gt; &lt;telerik:RadAjaxLoadingPanel ID="LoadingPanel1" runat="server" Style="width: 320px; padding-top: 125px;" Skin="Vista"&gt; &lt;/telerik:RadAjaxLoadingPanel&gt; &lt;table width="100%"&gt; &lt;tr style="height: 25px"&gt; &lt;td&gt; &lt;/td&gt; &lt;td&gt; &lt;/td&gt; &lt;/tr&gt; &lt;tr style="height: 100%"&gt; &lt;td style="width: 250px"&gt; &lt;telerik:RadPanelBar ID="IncidentReportPanel" runat="server" Height="450px" CssClass="IRPanel"&gt; &lt;Items&gt; &lt;telerik:RadPanelItem runat="server" Text="Incident Reports" ImageUrl="./Images/folder.gif" Value="IncidentReports"&gt; &lt;Items&gt; &lt;telerik:RadPanelItem&gt; &lt;ItemTemplate&gt; &lt;telerik:RadTreeView ID="IncidentReportsTreeView" runat="server" OnNodeExpand="LoadTreeNodes" OnNodeClick="PopulateIRData"&gt; &lt;Nodes&gt; &lt;telerik:RadTreeNode Text="Pending" ExpandMode="ServerSideCallBack" ImageUrl="./Images/completed.gif"&gt; &lt;/telerik:RadTreeNode&gt; &lt;telerik:RadTreeNode Text="Completed" ExpandMode="ServerSideCallBack" ImageUrl="./Images/completed.gif"&gt; &lt;/telerik:RadTreeNode&gt; &lt;/Nodes&gt; &lt;/telerik:RadTreeView&gt; &lt;/ItemTemplate&gt; &lt;/telerik:RadPanelItem&gt; &lt;/Items&gt; &lt;/telerik:RadPanelItem&gt; &lt;telerik:RadPanelItem runat="server" Text="Calendar" ImageUrl="./Images/calendar.gif" Value="Calendar"&gt; &lt;Items&gt; &lt;telerik:RadPanelItem&gt; &lt;ItemTemplate&gt; &lt;telerik:RadCalendar runat="server" ID="IRCalendar" Width="100%" /&gt; &lt;/ItemTemplate&gt; &lt;/telerik:RadPanelItem&gt; &lt;/Items&gt; &lt;/telerik:RadPanelItem&gt; &lt;/Items&gt; &lt;/telerik:RadPanelBar&gt; &lt;/td&gt; &lt;td&gt; &lt;asp:Panel ID="IRViewPanel" runat="server"&gt; &lt;telerik:RadTextBox ID="RadText" runat="server"&gt; &lt;/telerik:RadTextBox&gt; &lt;/asp:Panel&gt; &lt;/td&gt; &lt;/tr&gt; &lt;/table&gt; </code></pre> <p></p> <pre><code> protected void PopulateIRData(object sender, RadTreeNodeEventArgs e) { RadText.Text = "Hello, World!"; } </code></pre> <p>EDIT: I updated my code according to this article, <a href="http://www.telerik.com/help/aspnet-ajax/ajax-client-side-performance.html" rel="nofollow">http://www.telerik.com/help/aspnet-ajax/ajax-client-side-performance.html</a> , and the problem persisted... again it only happens the first time..</p> <p>EDIT: Just to clarify, by updating according to that article, I mean that I removed all the tables and relative widths and replaced them with css positioning and fixed widths.. the problem only happens the first time.. and it only happens sometimes.. quite a few times i thought i solved the problem as it would start responding quickly.. but then after I change my .aspx and change it back (even to the exact same thing when it was working quickly).. I get the same problem.. </p> <p>EDIT: So, I removed the AJAX component.. and setup the control so that it does a PostBack.. and it still takes long to hit my break point.. so it seems that its not an AJAX issue... but for some reason my events are taking long to fire..</p> <p>EDIT: So I followed the advice on this post and I used the webservices to do my binding and handle everything from the client side code.. All seemed to be ok until I decided that I wanted to return nodes from my webservice that could also be expanded.. So in my webservice I set the ExpandMode of my RadTreeNodeData object to Webservice.. and it renders the data correctly when I expand the child nodes.. However now I see the same problem from before where some calls take 20-30 seconds.. It takes 20-30 seconds to even hit the break point in my webservice.. Should I use the OnClientNodeExpand event instead? I don't understand why this is so slow!! Any help is greatly appreciated!</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload