public ActionResult EditMovie(MovieModel movieModel) //Update Movie [POST] { //Auto Mapper. var mapMovie = new MapperConfiguration(configExpression => { configExpression.CreateMap <MovieModel, Movie>(); }); IMapper mapper = mapMovie.CreateMapper(); var movie = mapper.Map <MovieModel, Movie>(movieModel); IEnumerable <OnlineMovieTicket.Entity.Category> category = categoryBL.CategoryDetails(); //Get category into movie edit movie details. ViewBag.categories = new SelectList(category, "CategoryId", "CategoryName"); movieBL.UpdateMovie(movie); TempData["Message"] = "Updated"; return(RedirectToAction("Index")); }