Esempio n. 1
0
 public void StopLogging()
 {
     if (ContinueThread || LogThread.IsAlive)
     {
         ContinueThread = false;
         LogThread.Join(1000);
     }
 }
Esempio n. 2
0
 public void Stop()
 {
     Trading = false;
     if (TradeThread?.ThreadState == ThreadState.Running)
     {
         TradeThread.Join();
     }
     if (LogThread.ThreadState == ThreadState.WaitSleepJoin)
     {
         LogThread.Abort();
     }
     else if (LogThread.ThreadState == ThreadState.Running)
     {
         LogThread.Join();
     }
 }