Esempio n. 1
0
 private void btnSWQuery_Click(object sender, EventArgs e)
 {
     if (SWWorker.IsBusy == false)
     {
         SWWorker.RunWorkerAsync();
     }
 }
Esempio n. 2
0
 private void SWWorker_DoWork(object sender, DoWorkEventArgs e)
 {
     try
     {
         SWWorker.ReportProgress(0, "Query Start");
         StockQuery query = new StockQuery();
         query.QueryStockWarrant();
         SWWorker.ReportProgress(0, "Query End");
     }
     catch (Exception ex)
     {
         SWWorker.ReportProgress(0, ex.Message);
     }
 }