コード例 #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            BIZView ViewStudents = new BIZView();

            gv.DataSource = ViewStudents.view();
            gv.DataBind();
        }
コード例 #2
0
        protected void btnDelete_Click(object sender, EventArgs e)
        {
            ex1.Text = "";
            int num = 0;

            BIZDelete DeleteStudent = new BIZDelete();

            try
            {
                DeleteStudent.check(input.Text);
                num = 1;
            }
            catch (Exception ex)
            {
                ex1.Text = ex.Message;
                num      = 0;
            }

            if (num == 1)
            {
                DeleteStudent.Delete();
            }

            BIZView ViewStudent = new BIZView();

            gv.DataSource = ViewStudent.view();
            gv.DataBind();
        }