Пример #1
0
 public static FormController GetInstance()
 {
     if (instance == null)
     {
         instance = new FormController();
     }
     return(instance);
 }
Пример #2
0
 private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e)
 {
     MessageBox.Show("Старт");
     System.Threading.Thread.Sleep(100);
     MessageBox.Show("Инстанс");
     FormController.GetInstance();
     MessageBox.Show("Стоп");
     backgroundWorker1.CancelAsync();
 }