From my previous question(Create json using JavaScriptSerializer), In .ashx
file I am printing the json object using:
context.Response.ContentType = "application/json";
context.Response.Write(json);
I am calling this .ashx
file from default.aspx which has some javascript function inside its <head>
tag.
My question is :
How will I be able to call the javascript function from .ashx file after context.Response.Write(json);
?
UPDATE:
My ultimate goal is to achieve Server Side Processing for DataTable.In that i want to bind the rows with context menu using javascript function.
For that I am using following code to call .ashx
file:
$('#example').dataTable({
'bProcessing': true,
'bServerSide': true,
'sAjaxSource': '/data.ashx'
});