Exemple #1
0
        public void Register()
        {
            var dir = ExamCode;

            if (!Directory.Exists(dir))
            {
                Directory.CreateDirectory(dir);
            }
            secureJsonSerializer = new SecureJsonSerializer <Submission>(Path.Combine(dir, StudentID + ".dat"));
        }
 private void saveButton_Click(object sender, EventArgs e)
 {
     SecureJsonSerializer<ProgramGroupManagerData> pgmDataFile = new SecureJsonSerializer<ProgramGroupManagerData>("pgmSave.json");
     pgmDataFile.Save(Program.PGM.generateProgramGroupManagerData());
 }
 void Form1Closing(object sender, CancelEventArgs e)
 {
     MEW.Stop();
     SecureJsonSerializer<ProgramGroupManagerData> pgmDataFile = new SecureJsonSerializer<ProgramGroupManagerData>("pgmSave.json");
     pgmDataFile.Save(Program.PGM.generateProgramGroupManagerData());
     unregisterHotkeys();
     foreach (GlobalHotkey ghk in hotkeys)
     {
         ghk.Dispose();
     }
 }