System.Data.DataRowView.BeginEdit C# (CSharp) Метод

BeginEdit() публичный Метод

public BeginEdit ( ) : void
Результат void
        public void BeginEdit() => _delayBeginEdit = true;

Usage Example

Пример #1
0
        private void mapControlToCommandGrid_CellEndEdit(object sender, DataGridViewCellEventArgs e)
        {
            var Cell = mapControlToCommandGrid.Rows[e.RowIndex].Cells[e.ColumnIndex];
            var Row  = Cell.OwningRow;
            var Col  = Cell.OwningColumn;

            if (Col.IsDataBound && Col.Name == "CatCmdIdColumn")
            {
                if (mapControlToCommandGrid.CurrentCell.EditType == typeof(DataGridViewComboBoxEditingControl))
                {
                    DataGridViewComboBoxCell cb = (DataGridViewComboBoxCell)mapControlToCommandGrid[e.ColumnIndex, e.RowIndex];
                    cb.DataSource = catCmdsBindingSource;
                }
            }
            else if (Col.IsDataBound && Col.Name == "midiControlTypeColumn")
            {
                ControlType ctrlType    = (ControlType)Row.Cells["midiControlTypeColumn"].Value;
                CatCmd      CatCmdValue = (CatCmd)Row.Cells["CatCmdIdColumn"].Value;
                var         attr        = CatCmdDb.Get(CatCmdValue);
                if (attr.ControlType != ctrlType)
                {
                    System.Data.DataRowView obj = (System.Data.DataRowView)mapControlToCommandGrid.CurrentRow.DataBoundItem;
                    obj.BeginEdit();
                    obj.Row["CatCmdId"] = 0;
                    obj.EndEdit();
                }
            }
        }
All Usage Examples Of System.Data.DataRowView::BeginEdit