public ActionResult Index(FormCollection formdata, Customer CusObj) { string NRI_DATA = formdata["nri_flag"].ToString(); string Tobacco = formdata["tobbaco_user_flag"].ToString(); if (NRI_DATA == "true,false") { NRI_DATA = "1"; Response.Write("NRI = " + NRI_DATA); } else if (NRI_DATA == "false") { NRI_DATA = "0"; } if (Tobacco == "true,false") { Tobacco = "1"; Response.Write("NRI = " + Tobacco); } else if (Tobacco == "false") { Tobacco = "0"; } customer.SaveCustomer(formdata["first_name"], formdata["last_name"], Convert.ToInt32(formdata["gender_"]), Convert.ToDateTime(formdata["date_of_birth"]), NRI_DATA, Tobacco, formdata["Email_id"].ToString(), formdata["Address_Line1"].ToString(), formdata["Address_Line2"].ToString(), Convert.ToInt32(formdata["state"]), Convert.ToInt64(formdata["Phone_Number"]), CusObj.Nominee_name); TempData["Phone_Number"] = Convert.ToInt64(formdata["Phone_Number"]); return(RedirectToAction("Index", "Policy")); }