Exemple #1
0
 private void New2_KeyDown(object sender, KeyEventArgs e)
 {
     if (e.KeyCode == Keys.Back)
     {
         New1.Clear();
         New1.Focus();
         p = 1;
     }
 }
Exemple #2
0
 private void New4_TextChanged(object sender, EventArgs e)
 {
     if (old1.Text == "" && old2.Text == "" & old3.Text == "" && old4.Text == "")
     {
         label16.Visible = true;
         label16.Text    = "Fill all text  !";
         New1.Clear();
         New2.Clear();
         New3.Clear();
         New4.Clear();
         New1.Focus();
     }
     else
     {
         label16.Visible = false;
         Con1.Focus();
     }
 }
Exemple #3
0
        private void textBox1_TextChanged(object sender, EventArgs e)
        {
            if (old1.Text == "" && old2.Text == "" & old3.Text == "" && old4.Text == "")
            {
                label16.Visible = true;
                label16.Text    = "Password is in complite  !";
                old1.Clear();
                old2.Clear();
                old3.Clear();
                old4.Clear();
                old1.Focus();
            }
            else
            {
                if (con.State == ConnectionState.Closed)
                {
                    con.Open();
                }
                string a1 = old1.Text.ToString() + old2.Text.ToString() + old3.Text.ToString() + old4.Text.ToString();

                SqlCommand cmd      = new SqlCommand("Select Password from PasswordCheek", con);
                string     Password = cmd.ExecuteScalar().ToString();

                //   MessageBox.Show("Data"+a1+ "get"+ Password);
                if (a1 == Password)
                {
                    New1.Focus();
                    label16.Visible = false;
                }
                else
                {
                    label16.Visible = true;
                    label16.Text    = "Password is in complite  !";
                    old1.Clear();
                    old2.Clear();
                    old3.Clear();
                    old4.Clear();
                    old1.Focus();
                }
            }
        }
Exemple #4
0
 private void textBox9_TextChanged(object sender, EventArgs e)
 {
     New1.Focus();
 }