private bool Validate_txt_Username(AccountDBFunctions con) { if (txt_Username.Text.Trim() == "") { MessageBox.Show("Username must not be empty!", RBACManagerModel.GetApplicationTitle()); return false; } if (con.UsernameExists(txt_Username.Text.Trim())) { MessageBox.Show("A user with the name already exists!", RBACManagerModel.GetApplicationTitle()); return false; } return true; }
public CreateAccountDialog(AccountDBFunctions accountDBFunctions) { accountFunctions = accountDBFunctions; InitializeComponent(); }
public AccountModel(Mysql mysqlConnection) { this.accountFunctions = new AccountDBFunctions(mysqlConnection); LoadAccountList(); }