示例#1
0
 /// <summary>
 /// Releases the unmanaged resources used by the <see cref="CsvExportAdapter"/> object and optionally releases the managed resources.
 /// </summary>
 /// <param name="disposing">true to release both managed and unmanaged resources; false to release only unmanaged resources.</param>
 protected override void Dispose(bool disposing)
 {
     if (!m_disposed)
     {
         try
         {
             if (disposing)
             {
                 m_scheduleManager.Stop();
                 m_scheduleManager.Dispose();
             }
         }
         finally
         {
             m_disposed = true;          // Prevent duplicate dispose.
             base.Dispose(disposing);    // Call base class Dispose().
         }
     }
 }
 private void MainForm_FormClosed(object sender, FormClosingEventArgs e)
 {
     Backups.Dispose();
     RestartManager.Dispose();
 }