Hi,
The following is the code snippet what Im trying with ASP.NET MVC with ajx call to Action.
But action is not calling. Please help me?
$.ajax({
type: "POST",
url: "/Sample/TestSubmit",
data: $.toJSON(result),
contentType: "application/json;charset=utf-8",
dataType: "json",
success: function(msg) {
var succeed = msg == 'OK';
if (!succeed) {
alert(msg);
} else {
alert('Saved');
}
},
error: function(){
alert('failed to save');
}
});