示例#1
0
        private void btn_login_Click(object sender, EventArgs e)
        {
            string username = txt_username.Text;
            string password = txt_password.Text;

            StoreProcedure.sp_login(username, password);
            StoreProcedure.fn_login_admin(username, password);
            GlobalVariable._LowImageFilePath = GlobalMethod.GetLowImageFilePath("1");
            this.Close();
            th = new Thread(openHome);
            th.SetApartmentState(ApartmentState.STA);
            th.Start();
        }
示例#2
0
        private void btn_login_Click(object sender, EventArgs e)
        {
            string username = txt_username.Text;
            string password = txt_password.Text;

            StoreProcedure.sp_login(username, password);
            StoreProcedure.fn_login_admin(username, password);
            if (GlobalVariable._user_role == "")
            {
                this.Refresh();
                lbl_denied_info.Text = "Please Enter the correct info.";
            }
            else
            {
                this.Close();
                th = new Thread(openHome);
                th.SetApartmentState(ApartmentState.STA);
                th.Start();
            }
        }