private void cSubjectClassGV_CellContentClick(object sender, DataGridViewCellEventArgs e) { frmClassSchedule schedule = new frmClassSchedule(); schedule.uIDlbl.Text = (Int32.Parse(cSubjectClassGV.Rows[e.RowIndex].Cells["ID"].Value.ToString())).ToString(); schedule.Show(); }
/// <summary> /// once a content from a cell is clicked, the class id and subject id /// is stored in a variable and passes to the scheduling form which display the details /// of the class eg. days and times for that specific class /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void SKLclasslistGV_CellContentClick(object sender, DataGridViewCellEventArgs e) { //sID = Int32.Parse(SKLclasslistGV.Rows[e.RowIndex].Cells["SID"].Value.ToString()); cID = Int32.Parse(SKLclasslistGV.Rows[e.RowIndex].Cells["ID"].Value.ToString()); frmClassSchedule schedule = new frmClassSchedule(); schedule.uIDlbl.Text = cID.ToString(); schedule.Show(); }
private void teachercoursesGV_CellContentClick(object sender, DataGridViewCellEventArgs e) { tID = Convert.ToInt32(ctTeacherIDTB.Text); subcode = Int32.Parse(teachercoursesGV.Rows[e.RowIndex].Cells["ID"].Value.ToString()); frmClassSchedule schedule = new frmClassSchedule(); schedule.uIDlbl.Text = tID.ToString(); //schedule.subID.Text = subcode.ToString(); schedule.Show(); }