예제 #1
0
파일: Login.cs 프로젝트: mewtcor/AppDevProj
        private void btnLogin_Click(object sender, EventArgs e)
        {
            LoginClass lclass   = new LoginClass();
            string     username = txtUsername.Text;
            string     password = txtPassword.Text;
            string     uaccess  = "";
            string     UsrRole  = lclass.validateLogin(username, password, uaccess);

            if (UsrRole == "Administrator")
            {
                Hide();
                AdminDash adForm = new AdminDash();
                adForm.Show();
                Hide();
            }
            else if (UsrRole == "Assistant")
            {
                Hide();
                //show Assistant Dash
                AssistantDash astForm = new AssistantDash();
                astForm.Show();
            }
            else if (UsrRole == "Doctor")
            {
                Hide();
                //show Doctor Dash
                DoctorDash drForm = new DoctorDash();
                drForm.Show();
            }
        }
예제 #2
0
        private void adminToolStripMenuItem_Click(object sender, EventArgs e)
        {
            this.Hide();
            AdminDash adDash = new AdminDash();

            adDash.Show();
        }