Exemplo n.º 1
0
 private void SetTotalRowCount()
 {
     // InvokeRequired required compares the thread ID of the
     // calling thread to the thread ID of the creating thread.
     // If these threads are different, it returns true.
     if (this.lblTotalRowCount.InvokeRequired)
     {
         //call itself on the main thread
         SetTotalRowCountCallback d = new SetTotalRowCountCallback(SetTotalRowCount);
         this.Invoke(d);
     }
     else
     {
         this.lblTotalRowCount.Text = this.m_total_row_count.ToString();
     }
 }
Exemplo n.º 2
0
 private void SetTotalRowCount()
 {
     // InvokeRequired required compares the thread ID of the
     // calling thread to the thread ID of the creating thread.
     // If these threads are different, it returns true.
     if (this.lblTotalRowCount.InvokeRequired)
     {
         //call itself on the main thread
         SetTotalRowCountCallback d = new SetTotalRowCountCallback(SetTotalRowCount);
         this.Invoke(d);
     }
     else
     {
         this.lblTotalRowCount.Text = this.m_total_row_count.ToString();
     }
 }