Supose you have a class like this:
public class MyClass
{
public string FirstName { get; set; }
public string LastName { get; set; }
}
And an action method like this:
public JsonResult Test(string data)
{
// do something with data
var obj = new MyClass {FirstName = "Thiago", LastName = "Temple"};
return Json(obj);
}
Then you can write a js function using jquery like this:
$.get('<%= Html.Action("Test", "MyController")', {data: "some value"}, function(result){
alert(result.FirstName + " " + result.LastName);
});
I hope this example is useful.