Пример #1
0
 private void DiveTypeInput_dataGridView_EditingControlShowing(object sender, DataGridViewEditingControlShowingEventArgs e)
 {
     if (((DataGridView)sender).CurrentCell.ColumnIndex == 0)
     {
         ComboBox cb = e.Control as ComboBox;
         if (cb != null)
         {
             //lägger till en Eventhandler på Position comboboxen
             cb.SelectionChangeCommitted -= new EventHandler(DataGridViewPositionSelectionChangeCommitted);
             cb.SelectionChangeCommitted += new EventHandler(DataGridViewPositionSelectionChangeCommitted);
         }
     }
     NewEventPresenter.AddAutoCompleteToDataGridView(_dataGridViewList, tabControl1, e, _diveNo, _diveNoReadOnly, _diveName, _diveNameReadOnly, groupBoxDisciplin);
 }
Пример #2
0
 //autocomplete
 private void dataGridView1_EditingControlShowing(object sender, DataGridViewEditingControlShowingEventArgs e)
 {
     NewEventPresenter.AddAutoCompleteToDataGridView(_dataGridViewList, tabControl1, e, _diveNo, _diveNoReadOnly, _diveName, _diveNameReadOnly, groupBoxDisciplin);
     PanelDrawer.Colorize(this);
 }