public bool New_registration(MobUser mob) { mySqlConnection db = new mySqlConnection(); bool result = db.ExecuteQuery("INSERT INTO tbl_app_users(au_firstname) VALUES ('" + mob.au_firstname + "')"); return(result); }
public ActionResult Create(MobUser mob) { try { appuser_repo obj = new appuser_repo(); var result = obj.New_registration(mob); if (result) { return(RedirectToAction("index")); } else { return(RedirectToAction("Create")); } } catch { return(View()); } }