Example #1
0
 private void buttonBack_Click(object sender, EventArgs e)
 {
     if (CheckUserType() == "admin")
     {
         changer.ShowAdminMain();
     }
     else if (CheckUserType() == "user")
     {
         changer.ShowUserView();
     }
 }
Example #2
0
 private void buttonLogin_Click(object sender, EventArgs e)
 {
     errorProvider.Clear();
     if (SendLogin(Login, Password) == "admin")
     {
         changer.ShowAdminMain();
     }
     else if (SendLogin(Login, Password) == "user")
     {
         changer.ShowUserView();
     }
     else
     {
         textBoxLogin.Clear();
         textBoxPassword.Clear();
         errorProvider.SetError(textBoxPassword, "Błędna nazwa użytkownika lub hasło");
     }
 }
Example #3
0
 private void buttonBack_Click(object sender, EventArgs e)
 {
     changer.ShowAdminMain();
 }