Exemplo n.º 1
0
 //_________________________________________________________________________
 private void BStartScan_Click(object sender, EventArgs e)
 {
     if (TScanParam.Enabled == true)
     {
         TScanParam.Stop();
         BStartScan.Text = "Пуск";
     }
     else
     {
         if (ВсегоПараметров > 0)
         {
             TScanParam.Interval = (int)NIntervalScan.Value;
             TScanParam.Enabled  = true;
             BStartScan.Text     = "Стоп";
         }
     }
 }
Exemplo n.º 2
0
 //_________________________________________________________________________
 private void FTestDrivers_FormClosing(object sender, FormClosingEventArgs e)
 {
     if (MessageBox.Show("Кончить тестирование драйвера?", "Завершение работы программы", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
     {
         if (DRV != null)
         {
             DRV.Close();
         }
         TScanParam.Dispose();
         TScanParam.Stop();
         TrStatExchange.Dispose();
         TrStatExchange.Stop();
         TrWorkTime.Stop();
         Devices.Save();
         Params.Save();
         Properties.Settings.Default.Save();
     }
     else
     {
         e.Cancel = true;
     }
 }