public ActionResult Register(User user) { int count = 0; if (ModelState.IsValid) { count = addData.InsertUser(user); if (count == 1) { ViewBag.Status = "User account created successfully!"; } else { ViewBag.Status = "Error! " + addData.message; } } return(View("Login")); }