public ActionResult Edit(FirmExt model)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    string Msg = "";
                    FirmRepository uRepo = new FirmRepository();
                    if (uRepo.Update(model, ref Msg, this))
                    {
                        return RedirectToAction("Index", "Firm");
                    }
                }
                catch (Exception ex)
                {
                    string hostName1 = Dns.GetHostName();
                    string GetUserIPAddress = Dns.GetHostByName(hostName1).AddressList[0].ToString();
                    string PageName = Convert.ToString(Session["PageName"]);
                    //string GetUserIPAddress = GetUserIPAddress1();
                    using (BaseRepository baseRepo = new BaseRepository())
                    {
                        //BizContext BizContext1 = new BizContext();
                        BizApplication.AddError(baseRepo.BizDB, PageName, ex.Message, ex.StackTrace, DateTime.Now, GetUserIPAddress);
                    }
                    Session["PageName"] = "";
                    ModelState.AddModelError("", "Error: Please Correct/Enter All the Information below to Save this Record, All Fields are Mandatory");
                    ErrorHandling.HandleModelStateException(ex, ModelState);
                }
            }

            return View(model);
        }
        public void BindViewBags(FirmExt firm)
        {
            ViewBag.Countries = DropDownLists.GetCountries(firm.CountryID);

            ViewBag.Status = DropDownLists.GetStatus(firm.StatusID);

            ViewBag.Title = DropDownLists.GetStatus(firm.ExecutiveTitleID);
        }