public ActionResult ProfilePage(double?id, string ed) { if (Session["User"] == null) { return(RedirectToAction("LogIn", "LogIn")); } if (((tbl_UserDetail)Session["User"]).GroupPages.Contains("Profile")) { try { if (id != null) { var x = MvcHelper.GetGroupRoleMappingMaster(Convert.ToInt32(id)); if (!string.IsNullOrEmpty(ed) && ed.Equals("2")) { x.ApproveStat = string.Empty; } ViewBag.obj = x; ViewBag.hid = id; } } catch (Exception ex) { TempData["Error"] = "Something went wrong."; } ViewBag.groupList = MvcHelper.GetGroupRoleMappingMasterList(); } return(View()); }