Пример #1
0
        private void LoginButton_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrEmpty(usernameTextBox.Text) || string.IsNullOrEmpty(passwordTextBox.Text))
            {
                _dialogWrapper.ShowMessageBox(@"Please provide Username and Password", @"Critical Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                return;
            }
            UserName = usernameTextBox.Text;
            Password = passwordTextBox.Text;
            passwordTextBox.Clear();
            usernameTextBox.Clear();

            DialogResult = DialogResult.OK;
        }
Пример #2
0
 private void ShowErrorDialog()
 {
     _dialogWrapper.ShowMessageBox("Incorrect user name or password!", @"Skyresponse", MessageBoxButtons.OK, MessageBoxIcon.Error);
 }