public void Connexion_Button_OnClick(object sender, RoutedEventArgs e) { if (!Login_TextBox.Text.Equals("") && !Password_TextBox.Password.Equals("")) { if (JediTournamentManager.CheckConnexionUser(Login_TextBox.Text, Password_TextBox.Password)) { ApplicationWPF.MainWindow mw = new ApplicationWPF.MainWindow(); mw.Show(); this.Close(); } } }