public ActionResult Delete(int id) { //call model method DeleteOne() data.DeleteOne(id); //redirect to index return(RedirectToAction("Index")); }