public ActionResult CheckAdminLogin(string UserEmail, string UserPassword) { ResultResponse result = new ResultResponse(); UserInformation users = adminDAL.AdminUserLogin(UserEmail, UserPassword); if (users.Empty) { result.isSuccess = true; result.msg = "Wrong Username Or Password"; return(Json(result, JsonRequestBehavior.AllowGet)); } else { result.isSuccess = false; result.msg = Url.Action("DashboardAdmin", "Admin"); Session["SQAdminID"] = users.UserInformationId; Session["SQAdminName"] = users.UserInformationName; Session["SQAdminEmail"] = users.UserInformationEmail; return(Json(result, JsonRequestBehavior.AllowGet)); } }