private void OpenTimetable(Data data) { this.Cursor = Cursors.WaitCursor; FormTimetable childForm = new FormTimetable(data); childForm.MdiParent = this; childForm.Show(); this.Cursor = Cursors.Default; }
public FormTimetable(Data data) { m_data = data; InitializeComponent(); UpdateGrids(); }
public ButtonView(Data data) { m_data = data; this.Text = data.Name; this.AutoSize = true; }
private void OpenTimetable(Data data, int ot) { FormTimetable childForm = new FormTimetable(data); //childForm.MdiParent = this; childForm.FormBorderStyle = FormBorderStyle.None; childForm.WindowState = FormWindowState.Maximized; childForm.Show(); ask_to_export(); System.Threading.Thread.Sleep(500); if (expotchoice == 1) { capture_Image(); childForm.Close(); exportingtimetables(ot, data.Name); ask_to_open(); if (expotchoiceopen == 1) { opendirectorytimetables(ot); } } childForm.Close(); }
public Lesson FindLesson(Data data, int time, int day) { if (data is Lecturer) { foreach (Lesson lesson in Lessons) { if (lesson.Lecturer == data && (lesson.Time == time && lesson.Day == day)) { return lesson; } } } else if (data is Module) { foreach (Lesson lesson in Lessons) { if (lesson.Module == data && (lesson.Time == time && lesson.Day == day)) { return lesson; } } } else if (data is Room) { foreach (Lesson lesson in Lessons) { if (lesson.Room == data && (lesson.Time == time && lesson.Day == day)) { return lesson; } } } else if (data is Group) { foreach (Lesson lesson in Lessons) { if (lesson.Group == data && (lesson.Time == time && lesson.Day == day)) { return lesson; } } } return null; }