Esempio n. 1
0
        private void ShowRequireInfo_Load(object sender, EventArgs e)
        {
            //labelShow.Text="Name    Secore";
            //if (ShowSelect.flag[])
            {
                for (int k = 0; k < StudentList.studentNum; k++)
                {
                    Student STU = new Student();
                    STU = StudentList.ShowAllStudent(k);
                    listBox1.Items.Add(Convert.ToString(STU.STRNAME));
                    listBox2.Items.Add(Convert.ToString(STU.STRID));
                    listBox3.Items.Add(Convert.ToString(STU.STRCLASS));
                    listBox4.Items.Add(Convert.ToString(STU.CHINESE));
                    listBox5.Items.Add(Convert.ToString(STU.MATH));
                    listBox6.Items.Add(Convert.ToString(STU.ENGLISH));
                    listBox7.Items.Add(Convert.ToString(STU.ALL));

                    //labelShow.Text = Convert.ToString(STU.STRNAME + "      " +
                    //    "      " + STU.STRID + "      " + STU.STRCLASS + "      " +
                    //    "      " + STU.CHINESE + "      " + STU.MATH + "      " +
                    //    "      " + STU.ENGLISH + "      " + STU.ALL);
                }
                if (StudentList.Average() != 0)
                {
                    textBoxAvarage.Text = Convert.ToString(StudentList.Average());
                }
            }

            //ShowSelect ShowSelectDlg = new ShowSelect();
            //if (ShowSelectDlg.)
            //{
            //}

            //if (Convert.ToBoolean(comboBoxShow.Items.Add("sss")))
            //    labelShow.Text = "ssdfdfadf";
            labelShow.Text = "Hello";
            comboBoxShow.Items.Add("The Top of Three");
            comboBoxShow.Items.Add("Failing");
            comboBoxShow.Items.Add("Analysis Chinese");
            comboBoxShow.Items.Add("Analysis Math");
            comboBoxShow.Items.Add("Analysis English");
        }
        private void ShowRequireInfo_Load(object sender, EventArgs e)
        {
            comboBoxShow.Items.Add("The Top of Three");
            //comboBoxShow.Items.Add("Failing");
            comboBoxShow.Items.Add("Analysis Chinese");
            comboBoxShow.Items.Add("Analysis Math");
            comboBoxShow.Items.Add("Analysis English");


            //listBox中展示所有学生成绩
            for (int k = 0; k < StudentList.i; k++)
            {
                Student STU = new Student();
                STU = StudentList.ShowAllStudent(k);
                listBox1.Items.Add(Convert.ToString(STU.STRNAME));
                listBox2.Items.Add(Convert.ToString(STU.STRID));
                listBox3.Items.Add(Convert.ToString(STU.STRCLASS));
                listBox4.Items.Add(Convert.ToString(STU.CHINESE));
                listBox5.Items.Add(Convert.ToString(STU.MATH));
                listBox6.Items.Add(Convert.ToString(STU.ENGLISH));
                listBox7.Items.Add(Convert.ToString(STU.ALL));

                //labelShow.Text = Convert.ToString(STU.STRNAME + "      " +
                //    "      " + STU.STRID + "      " + STU.STRCLASS + "      " +
                //    "      " + STU.CHINESE + "      " + STU.MATH + "      " +
                //    "      " + STU.ENGLISH + "      " + STU.ALL);
            }
            //求总分平均数模块
            if (StudentList.Average() != 0)
            {
                textBoxAvarage.Text = Convert.ToString(StudentList.Average());
            }

            //labelShow.Text = Convert.ToString(STU.STRNAME + "      " +
            //    "      " + STU.STRID + "      " + STU.STRCLASS + "      " +
            //    "      " + STU.CHINESE + "      " + STU.MATH + "      " +
            //    "      " + STU.ENGLISH + "      " + STU.ALL);
        }