Advertisement
Guest User

Auth

a guest
Jun 20th, 2019
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.84 KB | None | 0 0
  1.         int accesslogin = collator.compare(loginfield, UserLogin);
  2.         if (accesslogin < 0){
  3.             System.out.println("Введены неверные данные");
  4.         } else {authaccess = authaccess + 1;}
  5.         int accesspass = collator.compare(passfield, UserPass);
  6.         if (accesspass < 0){
  7.             System.out.println("Введены неверные данные");
  8.         } else {authaccess = authaccess + 1;}
  9.  
  10.         doauth.setOnAction(event -> {
  11.             System.out.println("Нажата кнопка Войти");
  12.             System.out.println("Ждемс.....");
  13.             if (authaccess == 2) {
  14.                 System.out.println("Логин и пароль верны");
  15.             } else {
  16.                 System.out.println("Неверный логин и пароль");
  17.             }
  18.  
  19.         });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement