public JsonResult GetAll() { StudentDAL dal = new StudentDAL(); var list = dal.GetAll(); return(Json(list, JsonRequestBehavior.AllowGet)); }
public static List <Student> GetAll() { using (StudentDAL studentDAL = new StudentDAL()) { return(studentDAL.GetAll()); } }
public IQueryable <Student> GetAll() { StudentDAL dalObject = new StudentDAL(); IQueryable <Student> results = dalObject.GetAll(); return(results); }
// GET: Student public ActionResult Index() { List <Student> students = studentDAL.GetAll(); ViewData["statuses"] = statusDAL.GetAll(); return(View(students)); }
public IEnumerable <Object> GetAll() { try { return(_studentDAL.GetAll()); } catch (Exception ex) { throw new Exception("Error from StudentBLL: " + ex.Message.ToString()); } }