I am using the ajaxRequest functionality to explicitly fire an ajax postback event from my javascript code.
I have a javascript function that generates the callback like this:
and, a function in the server side code, like this:
I have verified that, when the ajaxManager.ajaxRequest(args); line is executed in my client-side javascript, the value of "args" is correct (it is a comma seperated list of values).
But, when I try to access the argument in the server side code, the value in e.Argument is just a string that says "[Object object]".
I can't figure out what is causing this. Has anyone seen this behavior before? What have I done wrong? The examples I have seen, and that I am following make it look pretty simple but, I have somehow managed to make it weird.
Thanks for any help you can provide.
I have a javascript function that generates the callback like this:
<telerik:RadCodeBlock ID="codeBlock" runat="server"> |
<script type="text/javascript"> |
//<![CDATA[ |
function callPostbackFunction(args) |
{ |
var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>"); |
ajaxManager.ajaxRequest(args); |
} |
//]]> |
</script> |
</telerik:RadCodeBlock> |
protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e) |
{ |
String[] list; |
list = e.Argument.Split(','); |
String tmp; |
for (int i = 0; i < list.Length; i++) { |
tmp = list[i]; |
} |
} |
I have verified that, when the ajaxManager.ajaxRequest(args); line is executed in my client-side javascript, the value of "args" is correct (it is a comma seperated list of values).
But, when I try to access the argument in the server side code, the value in e.Argument is just a string that says "[Object object]".
I can't figure out what is causing this. Has anyone seen this behavior before? What have I done wrong? The examples I have seen, and that I am following make it look pretty simple but, I have somehow managed to make it weird.
Thanks for any help you can provide.