public ActionResult Create(ContactsMapper mContact) { IMapper mapper = AutoMapperInitializer.getMapper(); var contact = mapper.Map <Contacts>(mContact); var back = mapper.Map <ContactsMapper>(contact); var dataContext = new PetaPoco.Database("sqladdress"); dataContext.Insert(contact); return(RedirectToAction("Index")); }