[HttpPost] public ActionResult Create([Bind(Include = "EmpId,Name,Department,Mobile,Address")] employee Employee) { if (ModelState.IsValid) { dc.Employees.Add(Employee); dc.SaveChanges(); return RedirectToAction("Index"); } return View(Employee); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)