1.

What is JsonResultType (JavaScript Object Notation Result Type) in ASP.NET MVC?

Answer»

Action methods on controllers will return JsonResult that will be used WITHIN an AJAX application. From the “ActionResult” abstract CLASS, this JsonResult class will be inherited. Here Json will be supplied with a SINGLE argument that must be serializable. The JSONResult OBJECT will SERIALIZE the specified object into JSON format.

Example:

public JsonResult JsonResultExample(){ return Json("Hello InterviewBit!!");}


Discussion

No Comment Found