Example #1
0
        private async void button4_Click(object sender, EventArgs e)
        {
            if (textUserId.Text.Equals("") || textBox2.Text.Equals(""))
            {
                MessageBox.Show("User Name and Password cannot be empty", "Error", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
            else
            {
                //var userFound = await CheckLogin.Operations(textBox1.Text, textBox2.Text);
                var userFound = false;
                if (userFound)
                {
                    MessageBox.Show("User already exists, Please login", "Error", MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
                else
                {
                    await CheckLogin.Registrations(textUserId.Text, textBox2.Text);

                    MessageBox.Show("Registration Successful", "Congratulations", MessageBoxButtons.OK, MessageBoxIcon.Information);
                }
            }
        }
Example #2
0
 private async void cmdLogin_Click(object sender, EventArgs e)
 {
     var validateUser = await CheckLogin.Operations(textUserId.Text, textBox2.Text);
 }