public ActionResult Delete(int id, FormCollection collection) { try { _repository.DeleteAccounts(id); return(RedirectToAction("Index")); } catch { return(View()); } }