public void IncorrectPreviousPasswordEntered() { PreviousPassword.Clear(); PasswordBox1.Clear(); PasswordBox2.Clear(); IncorrectPasswordLabel.Visible = true; }
public void ClearTextBoxes() { PreviousPassword.Clear(); PasswordBox1.Clear(); PasswordBox2.Clear(); IncorrectPasswordLabel.Visible = false; }
private void buttonSubmit_Click(object sender, RoutedEventArgs e) { string msg; if (textBoxLogin.Text != "admin") { if ((string.IsNullOrWhiteSpace(textBoxLogin.Text)) || (string.IsNullOrWhiteSpace(PasswordBox.Password)) || (string.IsNullOrWhiteSpace(PasswordBox2.Password))) { MessageBox.Show("You have to input all fields!"); } else { if (PasswordBox.Password != PasswordBox2.Password) { MessageBox.Show("Passwords do not coincide. Try again!"); PasswordBox.Clear(); PasswordBox2.Clear(); } else { MethodsForPersons.AddPerson(textBoxLogin.Text, PasswordBox.Password, out msg); MessageBox.Show(msg); NavigationService.Navigate(new AuthorizationPage()); } } } else { MessageBox.Show("You can't use this login."); } }
private void ClearButton_Click(object sender, RoutedEventArgs e) { loginBox.Clear(); PasswordBox.Clear(); PasswordBox2.Clear(); Name.Clear(); Surname.Clear(); }
private void ConfirmButton_Click(object sender, EventArgs e) { if (PasswordBox1.Text == PasswordBox2.Text) { Client.WriteToStream(_stream, "%change%"); Client.WriteToStream(_stream, PasswordBox1.Text); } else { MessageBox.Show(" Passwords don't match !"); } PasswordBox1.Clear(); PasswordBox2.Clear(); }
public void ClearTextBoxes() { UserNameChoice.Clear(); PasswordBox1.Clear(); PasswordBox2.Clear(); }