Exemplo n.º 1
0
        public override object Clone()
        {
            RadarTextBoxDataGridViewColumn column = (RadarTextBoxDataGridViewColumn)base.Clone();

            column.RadarForm         = RadarForm;
            column.DescriptionColumn = DescriptionColumn;
            column.CharacterCasing   = CharacterCasing;
            column.TrimResult        = TrimResult;
            return(column);
        }
Exemplo n.º 2
0
        public override void InitializeEditingControl(int rowIndex, object
                                                      initialFormattedValue, DataGridViewCellStyle dataGridViewCellStyle)
        {
            RadarTextBoxDataGridViewControl ctl =
                DataGridView.EditingControl as RadarTextBoxDataGridViewControl;

            //ctl.Text = (this.Value is System.DBNull) ? string.Empty : (string)this.Value;
            ctl.Text = (initialFormattedValue is System.DBNull) ? string.Empty : (string)initialFormattedValue;
            DataGridViewColumn dgvc = this.OwningColumn;

            if (dgvc is RadarTextBoxDataGridViewColumn)
            {
                RadarTextBoxDataGridViewColumn rtvc = dgvc as RadarTextBoxDataGridViewColumn;
                ctl.RadarForm         = rtvc.RadarForm;
                ctl.DescriptionColumn = rtvc.DescriptionColumn;
                ctl.CharacterCasing   = rtvc.CharacterCasing;
                ctl.TrimResult        = rtvc.TrimResult;
            }

            // Set the value of the editing control to the current cell value.
            base.InitializeEditingControl(rowIndex, initialFormattedValue,
                                          dataGridViewCellStyle);
        }