partial void DeleteCountry(Country instance);
partial void InsertCountry(Country instance);
partial void UpdateCountry(Country instance);
public ActionResult AddLocation(CountryModel cmodel) { try { HolidayPlanner.DAL.Country ct = new HolidayPlanner.DAL.Country() { CountryId = cmodel.CountryId, CountryName = cmodel.CountryName }; context.Countries.InsertOnSubmit(ct); context.SubmitChanges(); return RedirectToAction("Index"); } catch { return View(cmodel); } }