Exemplo n.º 1
0
        private void ButtonLogin_Click(object sender, EventArgs e)
        {
            DBQuery query = new DBQuery();

            if (query.DBLogin(textBoxUsername.Text, textBoxPassword.Text))
            {
                MessageBox.Show("Welcome!");
                DialogResult = DialogResult.OK;
                Close();
            }
            else
            {
                MessageBox.Show("Incorrect username or password!");
            }
        }