예제 #1
0
 private void btnCheckStudent_Click(object sender, RoutedEventArgs e)
 {
     if (classSchedule.SelectedAppointment != null)
     {
         ScheduleAppointment appointment        = classSchedule.SelectedAppointment as ScheduleAppointment;
         CheckStudentWindow  checkStudentWindow = new CheckStudentWindow();
         checkStudentWindow.ClassId     = appointment.ClassId;
         checkStudentWindow.ScheduleId  = appointment.ScheduleId;
         checkStudentWindow.Appointment = appointment;
         if (checkStudentWindow.ShowDialog() == true)
         {
         }
     }
 }
예제 #2
0
파일: ViewModel.cs 프로젝트: wpmyj/LC
        private void CheckStudent(object parameter)
        {
            IEnumerable appointments = parameter as IEnumerable;

            if (appointments != null)
            {
                foreach (ScheduleAppointment appointment in appointments.OfType <ScheduleAppointment>())
                {
                    CheckStudentWindow checkStudentWindow = new CheckStudentWindow();
                    checkStudentWindow.ClassId    = appointment.ClassId;
                    checkStudentWindow.ScheduleId = appointment.ScheduleId;
                    if (checkStudentWindow.ShowDialog() == true)
                    {
                    }
                }
            }
        }