private void timer1_Tick(object sender, EventArgs e) { i++; if (i % j == 0) { if (s.Equals("Yükleniyor")) { timer1.Enabled = false; newform.ShowDialog(); Form newf = new Yükleniyor("İşleniyor", 2); newf.ShowDialog(); this.Close(); } else { timer1.Enabled = false; this.Close(); } } }
private void girişYap_Click(object sender, EventArgs e) { Form işle = new Yükleniyor("İşleniyor", 1); Form kapa = new Yükleniyor("İşleniyor", 2); this.Visible = false; işle.ShowDialog(); if (kullanıcı.Equals(kullanıcıt.Text) && şifre.Equals(parola.Text)) { parola.Text = null; Form nextform = new Ana_Menü(); nextform.ShowDialog(); } else { MessageBox.Show("PAROLA YANLIŞ VEYA HATALI KULLANICI...", "DİKKAT!!!", MessageBoxButtons.OK, MessageBoxIcon.Error); parola.Text = null; this.Visible = true; } }