New to Telerik UI for WinForms? Download free 30-day trial

Editors

RadVirtualGrid allows the users to edit the cells values. Usually this process starts by typing in the cell or by pressing F2. By default the editor type is determined according to the data value type. When in edit mode, the user can change the cell value and press Enter to commit the change or Esc to revert to the original value. Clicking outside the edited cell also commits the change.

Figure 1: Row editing indication

WinForms RadVirtualGrid Row editing indication

RadVirtualGrid can be made read-only by setting the AllowEdit property to false. In this case the editors would not appear.

Currently, RadVirtualGrid supports the following editors out of the box:

Editor type Description Image
VirtualGridCalculatorEditor Represents a calculator editor WinForms RadVirtualGrid VirtualGridCalculatorEditor
VirtualGridDateTimeEditor Represents a date time editor WinForms RadVirtualGrid VirtualGridDateTimeEditor
VirtualGridDropDownListEditor Represents a DropDownList editor WinForms RadVirtualGrid VirtualGridDropDownListEditor
VirtualGridMaskedEditBoxEditor Represents a masked editbox editor WinForms RadVirtualGrid VirtualGridMaskedEditBoxEditor
VirtualGridSpinEditor Represents a spin editor WinForms RadVirtualGrid VirtualGridSpinEditor
VirtualGridTextBoxControlEditor Represents a textbox control editor WinForms RadVirtualGrid VirtualGridTextBoxControlEditor
VirtualGridTextBoxEditor Represents a textbox editor WinForms RadVirtualGrid VirtualGridTextBoxEditor
VirtualGridTimePickerEditor Represents a time picker editor WinForms RadVirtualGrid VirtualGridTimePickerEditor
VirtualGridBrowseEditor Represents a browse editor WinForms RadVirtualGrid VirtualGridBrowseEditor
VirtualGridColorPickerEditor Represents a color editor WinForms RadVirtualGrid VirtualGridColorPickerEditor

RadVirtualGrid exposes an API for defining the data types of its columns. If the data type is explicitly set it wil determine the cell editors used in this column. Otherwise, the editor is determined by the cell value. The API works by column index.

Defining a Columns`s Data Type

this.radVirtualGrid1.MasterViewInfo.ColumnDataTypes[0] = typeof(int);

Me.radVirtualGrid1.MasterViewInfo.ColumnDataTypes(0) = GetType(Integer)

Reading a Columns`s Data Type

Type dataType = this.radVirtualGrid1.MasterViewInfo.GetColumnDataType(1);

Dim dataType As Type = Me.radVirtualGrid1.MasterViewInfo.GetColumnDataType(1)

See Also

In this article