示例#1
0
 //修改
 private void btnEdit_Click(object sender, EventArgs e)
 {
     if (this.myDataGridView1.DataSource == null)
     {
         return;
     }
     if (this.myDataGridView1.SelectedRows.Count >= 1)
     {
         AddCourseInfoForm frm = new AddCourseInfoForm(FormStatus.Update, int.Parse(this.myDataGridView1.CurrentRow.Cells[0].Value.ToString()));
         frm.Show();
     }
 }
示例#2
0
        //新增
        private void btnAdd_Click(object sender, EventArgs e)
        {
            AddCourseInfoForm frm = new AddCourseInfoForm(FormStatus.Add, null);

            frm.Show();
        }