-
Notifications
You must be signed in to change notification settings - Fork 0
/
Form1.cs
112 lines (105 loc) · 3.75 KB
/
Form1.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
using System.Diagnostics;
namespace BluescreenSimulator
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.ControlBox = false;
}
private void exit_button_Click(object sender, EventArgs e)
{
Application.Exit();
}
private void button2_Click(object sender, EventArgs e)
{
if (comboBox1.SelectedItem.ToString() == "Windows 10")
{
CRASH CRASH = new CRASH();
CRASH.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows 10 (happy)")
{
win10hbsod_t win10Hbsod_T = new win10hbsod_t();
win10Hbsod_T.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows XP to 7")
{
winxpt winxpt = new winxpt();
winxpt.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows 9x")
{
w9xt win9xt = new w9xt();
win9xt.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows 9x (system is busy)")
{
sbt sbt = new sbt();
sbt.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows 9x (warning)")
{
warningTimer warningTimer = new warningTimer();
warningTimer.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows NT")
{
windowsNTTimer windowsNTTimer = new windowsNTTimer();
windowsNTTimer.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows 1.0")
{
windows1Timer windows1Timer = new windows1Timer();
windows1Timer.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows Insider Build")
{
insiderTimer insiderTimer = new insiderTimer();
insiderTimer.ShowDialog();
this.Hide();
}
else if (comboBox1.SelectedItem.ToString() == "Windows Longhorn")
{
longhornTimer longhornTimer = new longhornTimer();
longhornTimer.ShowDialog();
this.Hide();
}
else
{
string m = "Please enter a valid entry.";
string t = "BluescreenSimulator";
MessageBox.Show(m, t);
}
}
private void label1_Click(object sender, EventArgs e)
{
string script = Path.Combine(Application.StartupPath, "repo.py");
if (File.Exists(script))
{
try
{
Process.Start("py.exe", script);
}
catch (Exception ex)
{
MessageBox.Show($"Error: {ex.Message}", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
else
{
MessageBox.Show("Script to open the repo page is not present", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
}