public ActionResult Edit(int id, FormCollection collection)
{
try
{
List<Employee> empList = GetEmployeeList();
var employee = empList.Single(m => m.ID == id);
if (TryUpdateModel(employee))
{
return RedirectToAction("Index");
}
return View(employee);
}
catch
{
return View();
}
}
Neither you are doing anything with collection Nor you are not catching the Employee object which is modified or ready to be updated.