public ActionResult GetUserInfo(string userid) { UserModels user = new UserModels(); DataTable dt = user.GetUserInfo(userid); var jsonResult = Json(JsonConvert.SerializeObject(dt), JsonRequestBehavior.AllowGet); return jsonResult; }