Esempio n. 1
0
 public void UpdateCombo(String Name)
 {
     // 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.dataGridViewCollection.InvokeRequired)
     {
         UpdateComboCallback d = new UpdateComboCallback(UpdateCombo);
         this.Invoke(d, new object[] { Name });
     }
     else
     {
         comboBoxDecks.Items.Add(Name);
     }
 }
 public void UpdateCombo(String Name)
 {
     // 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.dataGridViewCollection.InvokeRequired)
     {
         UpdateComboCallback d = new UpdateComboCallback(UpdateCombo);
         this.Invoke(d, new object[] { Name });
     }
     else
     {
         comboBoxDecks.Items.Add(Name);                
     }
 }