public Form5() { InitializeComponent(); Relief.classmax(); Relief.classcount(); button4.Hide(); Program.classno = 1001; Program.clzno = 1001; if (Program.maxclz == Program.classno) { button2.Hide(); } classshow(); textBox1.Text = Program.classname; }
private void button3_Click(object sender, EventArgs e) { if (textBox1.Text.Equals("")) { MessageBox.Show("Please Enter Valied Class !"); } else { Program.classname = textBox1.Text; Relief.timetablesearch(); Relief.resetter(); Relief.classload(); Relief.teachertime(); } }
public Form7() { InitializeComponent(); Relief.classmax(); Relief.classcount(); Program.classno = 1001; Program.clzno = 1001; for (int j = 0; j < Program.countc; j++) { Relief.classload(); Relief.teacherclear(); Relief.timeget(); Relief.abscheck(); Relief.teachertime(); for (int k = 0; k < 8; k++) { if (Program.testarr[k] != 0) { Program.newt[k] = Program.testarr[k]; } else { Program.newt[k] = Program.reliefarr[k]; } Relief.trelupdater(); } Relief.reliefclz(); Program.classno++; Program.clzno = Program.classno; } for (int k = 0; k < 8; k++) { Program.newt[k] = 0; Program.testarr[k] = 0; Program.reliefarr[k] = 0; } labelclear(); Program.relindex = 0; shower(); button1.Hide(); }
public void classshow() { Relief.resetter(); Relief.classload(); Relief.teachertime(); Relief.relieftime(); Relief.redsubshow(); Relief.bluesubshow(); for (int j = 0; j < 8; j++) { if (Program.redsub[j] == 0) { if (j == 0) { label20.ForeColor = Color.Red; } if (j == 1) { label21.ForeColor = Color.Red; } if (j == 2) { label22.ForeColor = Color.Red; } if (j == 3) { label23.ForeColor = Color.Red; } if (j == 4) { label24.ForeColor = Color.Red; } if (j == 5) { label25.ForeColor = Color.Red; } if (j == 6) { label26.ForeColor = Color.Red; } if (j == 7) { label27.ForeColor = Color.Red; } } if (Program.bluesub[j] == 1) { if (j == 0) { label12.ForeColor = Color.Blue; } if (j == 1) { label13.ForeColor = Color.Blue; } if (j == 2) { label14.ForeColor = Color.Blue; } if (j == 3) { label15.ForeColor = Color.Blue; } if (j == 4) { label16.ForeColor = Color.Blue; } if (j == 5) { label17.ForeColor = Color.Blue; } if (j == 6) { label18.ForeColor = Color.Blue; } if (j == 7) { label19.ForeColor = Color.Blue; } } } label12.Text = Convert.ToString(Program.rarr[0]); label13.Text = Convert.ToString(Program.rarr[1]); label14.Text = Convert.ToString(Program.rarr[2]); label15.Text = Convert.ToString(Program.rarr[3]); label16.Text = Convert.ToString(Program.rarr[4]); label17.Text = Convert.ToString(Program.rarr[5]); label18.Text = Convert.ToString(Program.rarr[6]); label19.Text = Convert.ToString(Program.rarr[7]); label20.Text = Convert.ToString(Program.tarr[0]); label21.Text = Convert.ToString(Program.tarr[1]); label22.Text = Convert.ToString(Program.tarr[2]); label23.Text = Convert.ToString(Program.tarr[3]); label24.Text = Convert.ToString(Program.tarr[4]); label25.Text = Convert.ToString(Program.tarr[5]); label26.Text = Convert.ToString(Program.tarr[6]); label27.Text = Convert.ToString(Program.tarr[7]); }