예제 #1
0
        protected void btnLogin_Click(object sender, EventArgs e)
        {
            //userName = "******";
            //password = "******";

            userName = Convert.ToString(txtUserName.Text);
            password = Convert.ToString(txtPassword.Text);

            bool login_status = clsCommon.checkLogin(userName, password);



            if (login_status == true)
            {
                string full_user_name = clsCommon.GetUserFullName(userName, password);
                string user_type      = clsCommon.user_type(userName, password);
                Session["USER_NAME"]      = userName;
                Session["USER_FULL_NAME"] = full_user_name;
                Session["USER_TYPE"]      = user_type;
                Response.Redirect("frmCircularSankey.aspx", false);
            }
            else
            {
                string script = "alert('" + "Please enter valid user name and password" + "');";
                ScriptManager.RegisterStartupScript(this, typeof(Page), "UserSecurity", script, true);
            }
        }