I found that the client side Ajax request of Telerik have a shot delay when fire ajaxRequest event.
Currently I create a RadGrid with check box. Each time user check on the check box it will update the database using AJAX without server postback so javascript is my choice.
I use prototype.js as my ajax request method and it working fine. Later I found that Telerik got own javascript AJAX request (ajaxRequest) method, I try to standardize my code all with Telerik only so I apply the ajaxRequest onto my code.
Telerik method work fine too, but do not no why the check box got shot delay each time I check on it.
Following code is my javascript use to call server update function. As in the code I only do a minimal changes. When remark the ajaxManager.ajaxRequest(pars) ,the check box will be normal, else the delay happen.
protoype.js
function UpdateValue(id,c, val) |
{ |
var url = "fn.aspx"; |
var pars = 'fn=u'; |
pars = pars + '&' + 'id=' + id + '&c=' + c + '&val=' + val; |
var myAjax = new Ajax.Request( |
url, |
{ |
method: 'post', |
parameters: pars, |
onComplete: response |
}); |
} |
Telerik ajaxRequest
function UpdateValue(id,c, val) |
{ |
var pars = 'fn=u'; |
pars = pars + '&' + 'id=' + id + '&c=' + c + '&val=' + val; |
var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>"); |
ajaxManager.ajaxRequest(pars); |
} |