Ejemplo n.º 1
0
 public static void SaveSettings(FacultiesAndGroups sett)
 {
     BinaryFormatter formatter = new BinaryFormatter();
     using (FileStream fs = new FileStream("Settings.dat", FileMode.Create))
     {
         formatter.Serialize(fs, sett);
     }
 }
Ejemplo n.º 2
0
        void CreateLocalCopy()
        {

            Storage = CurrentBase.EStorage;
            List<Faculty> localCopyOfFacultyList = new List<Faculty>();
            foreach (var item in CurrentBase.Faculties)
            {
                localCopyOfFacultyList.Add(item);
            }
            FacultiesAndGroups = new FacultiesAndGroups(localCopyOfFacultyList);
            groupsWithoutFaculty = new List<StudentSubGroup>();

        }
Ejemplo n.º 3
0
 private void FillFacultyAndCoursCombobox()
 {
     if (CurrentBase.BaseIsLoaded() && !CurrentSchedule.ScheduleIsFromFile())
     {
         facultiesAndGroups = new FacultiesAndGroups();
         foreach (Faculty faculty in facultiesAndGroups.Faculties)
         {
             facultComboBox.Items.Add(faculty.Name);
         }
         facultComboBox.SelectedIndex = -1;
         for (int i = 1; i <= 5; i++)
         {
             coursComboBox.Items.Add(i);
         }
         coursComboBox.SelectedIndex = -1;
         LoadFacultyAndGroups();
     }
     else { facultComboBox.IsEnabled = false; coursComboBox.IsEnabled = false; }
 }