示例#1
0
 private void PerformExpandOrCollapse(SWF.ComboBox combobox, bool droppedDown)
 {
     if (combobox.InvokeRequired == true)
     {
         combobox.BeginInvoke(new PerformExpandOrCollapseDelegate(PerformExpandOrCollapse),
                              new object [] { combobox, droppedDown });
         return;
     }
     combobox.DroppedDown = droppedDown;
 }
示例#2
0
 public void SetComboBoxText(ComboBox anything, string text)
 {
     anything.BeginInvoke((MethodInvoker)delegate
     {
         try
         {
             anything.Text = text;
         }
         catch
         {
         }
     });
 }
示例#3
0
 public void SetComboBoxState(ComboBox anything, bool state)
 {
     anything.BeginInvoke((MethodInvoker)delegate
     {
         try
         {
             anything.Enabled = state;
         }
         catch
         {
         }
     });
 }
示例#4
0
 public void SetComboBoxSelectItem(ComboBox anything, string text)
 {
     anything.BeginInvoke((MethodInvoker)delegate
     {
         try
         {
             anything.SelectedItem = text;
         }
         catch
         {
         }
     });
 }