private void Timer1_Tick(object sender, EventArgs e) { Random rnd = new Random(); pr += rnd.Next(cmin, cmax); if (pr >= 100) { pr = 100; RunCmd(cmd); Perc_Timer.Stop(); if (closeaftercmd) { password_in.Text = textBox7.Text; this.Close(); } } Perc_Timer.Interval = rnd.Next(tmin, tmax); }
private void Timer2_Tick(object sender, EventArgs e) { if (password_in.Text.Contains(textBox7.Text)) { button1.Visible = true; button2.Visible = true; Perc_Timer.Stop(); BSOD_Timer.Stop(); txt_1.ReadOnly = false; txt_2.ReadOnly = false; txt_3.ReadOnly = false; txt_4.ReadOnly = false; txt_5.ReadOnly = false; txt_6.ReadOnly = false; label2.Visible = true; textBox7.Visible = true; txt_1.Text = prevtxt_1; txt_2.Text = prevtxt_2; txt_3.Text = prevtxt_3; txt_4.Text = prevtxt_4; txt_5.Text = prevtxt_5; txt_6.Text = prevtxt_6; txt_1.SelectAll(); txt_1.SelectionColor = Color.WhiteSmoke; txt_2.SelectAll(); txt_2.SelectionColor = Color.WhiteSmoke; txt_3.SelectAll(); txt_3.SelectionColor = Color.WhiteSmoke; txt_4.SelectAll(); txt_4.SelectionColor = Color.WhiteSmoke; txt_5.SelectAll(); txt_5.SelectionColor = Color.WhiteSmoke; txt_6.SelectAll(); txt_6.SelectionColor = Color.WhiteSmoke; pr = 0; CursorShown = true; this.TopMost = false; this.Select(); password_in.Text = ""; } else { password_in.Select(); CursorShown = false; this.TopMost = true; FormatTexts(); } }