public ActionResult Create([Bind(Include = "id,firstName,lastName,email,phoneNumber")] Attendee attendee) { try { db.Attendees.Add(attendee); db.SaveChanges(); return(RedirectToAction("Index")); } catch (RetryLimitExceededException dex) { Console.Error.WriteLine("An error occurred while saving a new attendee"); Console.Error.WriteLine(dex.StackTrace); ModelState.AddModelError("", "Unable to save changes. Try again, and if the problem persists, see your system administrator"); } return(View(attendee)); }