// // GET: /NEWFORM/Add public ActionResult Add() { try { _sIMREG_REQUESTEDBYRepository = new SIMREG_REQUESTEDBYRepository(); _sIMREG_REQUESTEDTYPERepository = new SIMREG_REQUESTEDTYPERepository(); _sIMREG_DELIVEREDBYRepository = new SIMREG_DELIVEREDBYRepository(); var sIMREG_NEWFORMViewModel = new SIMREG_NEWFORMViewModel(); var sIMREG_REQUESTEDBYList = _sIMREG_REQUESTEDBYRepository.GetAll(); var sIMREG_REQUESTEDTYPEList = _sIMREG_REQUESTEDTYPERepository.GetAll(); var sIMREG_DELIVEREDBYList = _sIMREG_DELIVEREDBYRepository.GetAll(); sIMREG_NEWFORMViewModel.ddlREQUESTEDBYS = SelectListItemExtension.PopulateDropdownList(); return PartialView("_Add", sIMREG_NEWFORMViewModel); } catch (Exception ex) { ExceptionHelper.ExceptionMessageFormat(ex); return PartialView("_Error", ex); } }