public ActionResult Create(CA_RolePreferences ca_rolepreferences)
        {
            if (ModelState.IsValid)
            {
                db.CA_RolePreferences.Add(ca_rolepreferences);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            ViewBag.RoleID = new SelectList(db.MS_RoleMaster, "RoleID", "RoleDesc", ca_rolepreferences.RoleID);
            return View(ca_rolepreferences);
        }
 public ActionResult Edit(CA_RolePreferences ca_rolepreferences)
 {
     if (ModelState.IsValid)
     {
         db.Entry(ca_rolepreferences).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     ViewBag.RoleID = new SelectList(db.MS_RoleMaster, "RoleID", "RoleDesc", ca_rolepreferences.RoleID);
     return View(ca_rolepreferences);
 }