15 Answers, 1 is accepted
0
Hi Pavel,
Please report your question since it seems to be lost due to the duplication of the initial post.
Kind regards,
Stephen
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Please report your question since it seems to be lost due to the duplication of the initial post.
Kind regards,
Stephen
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Pavel
Top achievements
Rank 1
answered on 23 Jul 2008, 03:03 PM
I'm sorry for my connection once more. Here is my question:
I've encountered problem with simultaneous sending ajax request and expanding nodes with ServerSideCallBack expand mode. Node is never expanded in this case.
Pls see the following code.
If you run my example you'll see loading message "Accessing..." appears after page loading. It never disappears and root node is never expanded although it should. If you remove sending of ajax request all works fine. Loading message disappears and root node expanded (it's empty by design).
Is there any way to load node on demand when ajax request is in process?
I've encountered problem with simultaneous sending ajax request and expanding nodes with ServerSideCallBack expand mode. Node is never expanded in this case.
Pls see the following code.
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="TestTreeViewExpanding._Default" %> |
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %> |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
<html xmlns="http://www.w3.org/1999/xhtml"> |
<head runat="server"> |
<title>Test Page</title> |
</head> |
<body> |
<form id="form1" runat="server"> |
<asp:Panel ID="Panel1" runat="server"> |
<asp:ScriptManager ID="SM" runat="server" /> |
<script type="text/javascript"> |
function OnLoadTree() |
{ |
var ram = $find('<%= ram.ClientID %>'); |
ram.ajaxRequest(''); |
var tree = $find('<%= TreeView.ClientID %>'); |
tree.get_nodes().getNode(0).expand(); |
} |
Sys.Application.add_load(OnLoadTree); |
</script> |
</asp:Panel> |
<telerik:RadTreeView ID="TreeView" Runat="server" |
LoadingMessage="Accessing... "> |
<Nodes> |
<telerik:RadTreeNode Text="Root" ExpandMode="ServerSideCallBack" /> |
</Nodes> |
</telerik:RadTreeView> |
<telerik:RadAjaxManager ID="ram" runat="server" RequestQueueSize="5" /> |
</form> |
</body> |
</html> |
If you run my example you'll see loading message "Accessing..." appears after page loading. It never disappears and root node is never expanded although it should. If you remove sending of ajax request all works fine. Loading message disappears and root node expanded (it's empty by design).
Is there any way to load node on demand when ajax request is in process?
0
Pavel
Top achievements
Rank 1
answered on 11 Aug 2008, 05:39 PM
Can anyone comment this?
0
Hello Pavel,
I tested the code supplied, and the controls behaved as expected. Attached to this message, you will find the code, which I used for testing. Take a look at it and let me know if this is the expected behavior or I am leaving something out.
All the best,
Yavor
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
I tested the code supplied, and the controls behaved as expected. Attached to this message, you will find the code, which I used for testing. Take a look at it and let me know if this is the expected behavior or I am leaving something out.
All the best,
Yavor
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Pavel
Top achievements
Rank 1
answered on 12 Aug 2008, 09:44 AM
Attached example is correct. I checked it with the lastest version of Telerik (2.723). It works with Telerik for Net2.0. But it doesn't work correctly with Telerik for Net3.5 (the problem I described exists).
0
Pavel
Top achievements
Rank 1
answered on 14 Aug 2008, 08:15 AM
Yavor, can you reproduce described behavior with Telerik for Net 3.5?
0
Hello Pavel,
Yes, I was indeed able to replicate the erroneous behavior with the 3.5 version of the controls.
I will investigate the issue further, and update this thread as necessary.
Greetings,
Yavor
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Yes, I was indeed able to replicate the erroneous behavior with the 3.5 version of the controls.
I will investigate the issue further, and update this thread as necessary.
Greetings,
Yavor
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Pavel
Top achievements
Rank 1
answered on 14 Aug 2008, 11:04 AM
Thanks, Yavor. I'll be waiting for your reply.
0
Hi Pavel,
As I see from the code, on pageLoad() you are making an ajaxRequest and this is an endless cycle.
Can you explain in more detail what are you trying to achieve?
Kind regards,
Veskoni
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
As I see from the code, on pageLoad() you are making an ajaxRequest and this is an endless cycle.
Can you explain in more detail what are you trying to achieve?
Kind regards,
Veskoni
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Pavel
Top achievements
Rank 1
answered on 18 Aug 2008, 12:39 PM
Hi, Veskoni.
It's just an example. I tried to make as simple as I could. My page sends ajax requests during which user are able to expand tree nodes. And I see described behavior if node data is loaded on demand when another ajax request is in progress already.
I placed OnLoadTree() method in load event just to simplify example. I tried to add button and call OnLoadTree() method on clicking it and experienced the same behavior.
Is this something wrong with the calling OnLoadTree() method on page load? I'm quite new to web development and ajax so I can make stupid mistakes.
It's just an example. I tried to make as simple as I could. My page sends ajax requests during which user are able to expand tree nodes. And I see described behavior if node data is loaded on demand when another ajax request is in progress already.
I placed OnLoadTree() method in load event just to simplify example. I tried to add button and call OnLoadTree() method on clicking it and experienced the same behavior.
Is this something wrong with the calling OnLoadTree() method on page load? I'm quite new to web development and ajax so I can make stupid mistakes.
0
Hi Pavel,
Maybe it is better to disable the treeview while there is an Ajax request to the server.
You can check this help article:
Disable controls during AJAX
I hope this will get you started.
Greetings,
Veskoni
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Maybe it is better to disable the treeview while there is an Ajax request to the server.
You can check this help article:
Disable controls during AJAX
I hope this will get you started.
Greetings,
Veskoni
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Pavel
Top achievements
Rank 1
answered on 22 Aug 2008, 11:26 AM
Hi, Veskoni.
Thanks for advice. But I can't disable tree view cause it's main control on page. Actually I checked my example with respect to your previous post once more. I removed expand in OnLoad() handler (I replaced it with button click) and found that it's possible to expand node later (on third or second try to expand node) when request is finished. It's not very good but it's suitable solution.
Thank you for your help.
Thanks for advice. But I can't disable tree view cause it's main control on page. Actually I checked my example with respect to your previous post once more. I removed expand in OnLoad() handler (I replaced it with button click) and found that it's possible to expand node later (on third or second try to expand node) when request is finished. It's not very good but it's suitable solution.
Thank you for your help.
0
Daniel Sim
Top achievements
Rank 1
answered on 02 Dec 2009, 11:53 AM
I am experiencing this issue too.
1) Ajax request (a) started by user
2) Before request returns, user tries to expand node (b)
3) (a) returns from server
4) (b) never completes
Even enabling RadAjaxManager queue doesn't resolve this.
Does the RadTree use the RadAjaxManager? Other requests work okay, cancelling the (a) request as desired.
Dan
1) Ajax request (a) started by user
2) Before request returns, user tries to expand node (b)
3) (a) returns from server
4) (b) never completes
Even enabling RadAjaxManager queue doesn't resolve this.
Does the RadTree use the RadAjaxManager? Other requests work okay, cancelling the (a) request as desired.
Dan
0
Daniel Sim
Top achievements
Rank 1
answered on 03 Dec 2009, 11:32 AM
I can confim that expanding a treenode using ServerSideCallBack is not cancelling the RadAjaxManagerRequest.
Is this by design? Seems strange to me.
Dan
Is this by design? Seems strange to me.
Dan
0
Hi Daniel,
Can you please post the code, which you are presently using, so that I can replicate the issue with it locally, and make sure that we are on the same page.
Thank you.
Greetings,
Yavor
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Can you please post the code, which you are presently using, so that I can replicate the issue with it locally, and make sure that we are on the same page.
Thank you.
Greetings,
Yavor
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.