private void btnLogin_Click(object sender, EventArgs e) { if (" " + txtChapta.Text == lblChapta.Text) { int control = 0; UserBLL _userBLL = new UserBLL(); control = _userBLL.LoginControl(txtTC.Text, txtPassword.Text); if (control == -1) { DialogResult DRs = new DialogResult(); DRs = MessageBox.Show("Henüz üye değilsiniz\nÜye olmak istermisiniz?", "Uyarı", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (DRs == DialogResult.Yes) { SingUpForm singUpForm = new SingUpForm(); singUpForm.Show(); } } if (control >= 1) { AddReserveForm addReserveForm = new AddReserveForm(); _userID = control; this.Hide(); addReserveForm.Show(); } else if (control == 0) { MessageBox.Show("Hatalı şifre girdiniz.", "Uyarı", MessageBoxButtons.OK, MessageBoxIcon.Information); Random rnd = new Random(); _random = rnd.Next(10000, 99999); lblChapta.Text = " " + _random; } } else if (" " + txtChapta.Text != lblChapta.Text) { txtChapta.Text = "Sağda ne yazıyor?"; MessageBox.Show("Eşleşmeyen veya Doldurulmamış alanlar var.", "Uyarı", MessageBoxButtons.OK, MessageBoxIcon.Information); Random rnd = new Random(); _random = rnd.Next(10000, 99999); lblChapta.Text = " " + _random; } }
private void btnSingUp_Click(object sender, EventArgs e) { SingUpForm signUpForm = new SingUpForm(); signUpForm.Show(); }