Class RadVirtualGridElement
Represent the main element of RadVirtualGrid.
Inheritance
Inherited Members
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.GridView.dll
Syntax
public class RadVirtualGridElement : LightVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IComponent, IDisposable, IBindableComponent, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IImageElement, ITextPrimitive, ITextProvider
Constructors
RadVirtualGridElement()
Initializes a new instance of the RadVirtualGridElement class.
Declaration
public RadVirtualGridElement()
Properties
ActiveEditor
Gets the currently active editor when the grid is in edit mode.
Declaration
public IInputEditor ActiveEditor { get; }
Property Value
IInputEditor
|
AllowAddNewRow
Gets or sets a value indicating whether the add new row is visible.
Declaration
public bool AllowAddNewRow { get; set; }
Property Value
System.Boolean
|
AllowCellContextMenu
Gets or sets a value indicating whether right-clicking on a data cell will show the default data cell context menu.
Declaration
public bool AllowCellContextMenu { get; set; }
Property Value
System.Boolean
|
AllowColumnHeaderContextMenu
Gets or sets a value indicating whether right-clicking on a header cell will show the default header cell context menu.
Declaration
public bool AllowColumnHeaderContextMenu { get; set; }
Property Value
System.Boolean
|
AllowColumnResize
Gets or sets a value indicating whether users can resize columns through the grid UI.
Declaration
public bool AllowColumnResize { get; set; }
Property Value
System.Boolean
|
AllowCopy
Gets or sets a value indicating whether the Copy option in the context menu and the Ctrl+C shortcut will be available to the user.
Declaration
public bool AllowCopy { get; set; }
Property Value
System.Boolean
|
AllowCut
Gets or sets a value indicating whether the Cut option in the context menu and the Ctrl+X shortcut will be available to the user.
Declaration
public bool AllowCut { get; set; }
Property Value
System.Boolean
|
AllowDelete
Gets or sets a value indicating whether users can delete rows.
Declaration
public bool AllowDelete { get; set; }
Property Value
System.Boolean
|
AllowEdit
Gets or sets a value indicating whether users can edit the values in data cells.
Declaration
public bool AllowEdit { get; set; }
Property Value
System.Boolean
|
AllowFiltering
Gets or sets a value indicating whether the filter row is visible.
Declaration
public bool AllowFiltering { get; set; }
Property Value
System.Boolean
|
AllowMultiColumnSorting
Gets or sets a value indicating whether the users can sort by more than one column.
Declaration
public bool AllowMultiColumnSorting { get; set; }
Property Value
System.Boolean
|
AllowPaste
Gets or sets a value indicating whether the Paste option in the context menu and the Ctrl+V shortcut will be available to the user.
Declaration
public bool AllowPaste { get; set; }
Property Value
System.Boolean
|
AllowRowResize
Gets or sets a value indicating whether users can resize rows through the grid UI.
Declaration
public bool AllowRowResize { get; set; }
Property Value
System.Boolean
|
AllowSorting
Gets or sets a value indicating whether users can sort columns by clicking the header or through the header context menu.
Declaration
public bool AllowSorting { get; set; }
Property Value
System.Boolean
|
BeginEditMode
Gets or sets the method for entering edit mode.
Declaration
public RadVirtualGridBeginEditMode BeginEditMode { get; set; }
Property Value
RadVirtualGridBeginEditMode
|
ColumnCount
Gets or sets the total number of columns to be displayed in the grid.
Declaration
public int ColumnCount { get; set; }
Property Value
System.Int32
|
ContextMenu
Gets or sets the default context menu.
Declaration
public RadDropDownMenu ContextMenu { get; set; }
Property Value
RadDropDownMenu
|
CurrentCell
Gets or sets the current cell.
Declaration
public VirtualGridCellInfo CurrentCell { get; set; }
Property Value
VirtualGridCellInfo
|
EnableAlternatingRowColor
Gets or sets a value indicating whether event and odd rows will have a different back color.
Declaration
public bool EnableAlternatingRowColor { get; set; }
Property Value
System.Boolean
|
EnablePaging
Gets or sets a value indicating whether data is presented in chunks (pages) to the user.
Declaration
public bool EnablePaging { get; set; }
Property Value
System.Boolean
|
EnterKeyMode
Gets or sets the behavior of the Enter key when pressed while in edit mode.
Declaration
public RadVirtualGridEnterKeyMode EnterKeyMode { get; set; }
Property Value
RadVirtualGridEnterKeyMode
|
FilterDescriptors
Gets the filter descriptors currently applied to the grid.
Declaration
public FilterDescriptorCollection FilterDescriptors { get; }
Property Value
FilterDescriptorCollection
|
InputBehavior
Gets or sets an instance of VirtualGridInputBehavior which handles user input.
Declaration
public VirtualGridInputBehavior InputBehavior { get; set; }
Property Value
VirtualGridInputBehavior
|
IsInEditMode
Gets a value indicating whether the grid is in edit mode.
Declaration
public bool IsInEditMode { get; }
Property Value
System.Boolean
|
MasterViewInfo
Gets the main VirtualGridViewInfo instance of the grid.
Declaration
public VirtualGridViewInfo MasterViewInfo { get; }
Property Value
VirtualGridViewInfo
|
MultiSelect
Gets or sets a value indicating whether multiple cells can be selected simultaneously.
Declaration
public bool MultiSelect { get; set; }
Property Value
System.Boolean
|
PageIndex
Gets or sets the index of the page currently presented in the grid.
Declaration
public int PageIndex { get; set; }
Property Value
System.Int32
|
PageSize
Gets or sets the number of rows shown per page when paging is enabled.
Declaration
public int PageSize { get; set; }
Property Value
System.Int32
|
RowCount
Gets or sets the total number of rows to be displayed in the grid.
Declaration
public int RowCount { get; set; }
Property Value
System.Int32
|
Selection
Gets a VirtualGridSelection object which provides an API for manipulating the selection.
Declaration
public VirtualGridSelection Selection { get; }
Property Value
VirtualGridSelection
|
SelectionMode
Gets or sets a value indicating how cells are selected.
Declaration
public VirtualGridSelectionMode SelectionMode { get; set; }
Property Value
VirtualGridSelectionMode
|
ShowHeaderRow
Gets or sets a value indicating whether the header row is visible.
Declaration
public bool ShowHeaderRow { get; set; }
Property Value
System.Boolean
|
ShowNoDataText
Gets or sets a value indicating whether a message should be displayed in the grid when no data is loaded.
Declaration
public bool ShowNoDataText { get; set; }
Property Value
System.Boolean
|
SortDescriptors
Gets the sort descriptors currently applied to the grid.
Declaration
public SortDescriptorCollection SortDescriptors { get; }
Property Value
SortDescriptorCollection
|
StandardTab
Gets or sets a value indicating whether the TAB key moves the focus to the next control in the tab order rather than moving the focus to the next cell in the control.
Declaration
public bool StandardTab { get; set; }
Property Value
System.Boolean
|
TableElement
Gets an instance of VirtualGridTableElement which holds all rows and columns.
Declaration
public VirtualGridTableElement TableElement { get; }
Property Value
VirtualGridTableElement
|
TotalPages
Gets the total number of pages when paging is enabled.
Declaration
public int TotalPages { get; }
Property Value
System.Int32
|
UseScrollbarsInHierarchy
Gets or sets value indicating whether child views have fixed size [true] or depend on the number of rows they contain [false].
Declaration
public bool UseScrollbarsInHierarchy { get; set; }
Property Value
System.Boolean
|
Methods
BeginEdit()
Starts the editing process for the current cell.
Declaration
public bool BeginEdit()
Returns
System.Boolean
|
BeginEdit(VirtualGridCellElement)
Starts the editing process for the specified cell.
Declaration
public virtual bool BeginEdit(VirtualGridCellElement currentCell)
Parameters
VirtualGridCellElement
currentCell
The cell to open for editing. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
BeginUpdate()
Suspends layout updates.
Declaration
public void BeginUpdate()
BestFitColumn(Int32)
Widens / shrinks the column at the specified index in the specified view info based on the space required by the text in the cells.
Declaration
public void BestFitColumn(int columnIndex)
Parameters
System.Int32
columnIndex
The index of the column. |
BestFitColumn(Int32, VirtualGridViewInfo)
Widens / shrinks the column at the specified index in the specified view info based on the space required by the text in the cells.
Declaration
public void BestFitColumn(int columnIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
columnIndex
The index of the column. |
VirtualGridViewInfo
viewInfo
The view info to perform the operation on. |
BestFitColumns()
Widens / shrinks all columns based on the space required by the text in the cells.
Declaration
public void BestFitColumns()
BestFitColumns(VirtualGridViewInfo)
Widens / shrinks all columns in the specified view info based on the space required by the text in the cells.
Declaration
public void BestFitColumns(VirtualGridViewInfo viewInfo)
Parameters
VirtualGridViewInfo
viewInfo
The view info to perform the operation on. |
CancelEdit()
Ends the editing process without committing any changes. Returns a value indicating whether the operation succeeded.
Declaration
public virtual bool CancelEdit()
Returns
System.Boolean
Returns true if the operation is successful. Returns false if the operation is not successful e.g. the grid was not in edit mode. |
CanEndEdit()
Returns a value indicating whether the current editor can be closed.
Declaration
public virtual bool CanEndEdit()
Returns
System.Boolean
True if the editor can be closed, otherwise false. |
CollapseRow(Int32)
Collapses the specified row.
Declaration
public bool CollapseRow(int rowIndex)
Parameters
System.Int32
rowIndex
The row index to collapse. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
CommitNewRow()
Commits the value in the new row by firing the UserAddedRow event.
Declaration
public void CommitNewRow()
CopySelection()
Copies the content of the selected cells.
Declaration
public virtual bool CopySelection()
Returns
System.Boolean
True if the operation was successful, otherwise false. |
CopyToClipboard(Int32, Int32, Int32, Int32, VirtualGridViewInfo)
Copies the content of the specified cell region to the clipboard.
Declaration
public void CopyToClipboard(int startRow, int startColumn, int endRow, int endColumn, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
startRow
The index of the row where the content copy should start. |
System.Int32
startColumn
The index of the column where the content copy should start. |
System.Int32
endRow
The index of the row where the content copy should end. |
System.Int32
endColumn
The index of the column where the content copy should end. |
VirtualGridViewInfo
viewInfo
The view info of the cell region. |
CopyToClipboard(Int32, Int32, Int32, Int32, VirtualGridViewInfo, Boolean, Boolean)
Copies the content of the specified cell region to the clipboard.
Declaration
public void CopyToClipboard(int startRow, int startColumn, int endRow, int endColumn, VirtualGridViewInfo viewInfo, bool selectedOnly, bool cut)
Parameters
System.Int32
startRow
The index of the row where the content copy should start. |
System.Int32
startColumn
The index of the column where the content copy should start. |
System.Int32
endRow
The index of the row where the content copy should end. |
System.Int32
endColumn
The index of the column where the content copy should end. |
VirtualGridViewInfo
viewInfo
The view info of the cell region. |
System.Boolean
selectedOnly
Determines whether only selected cells are copied. |
System.Boolean
cut
Determines whether cell values should be cleared after the copy. |
CreateChildElements()
Called by the element when constructed. Allows inheritors to build the element tree.
Declaration
protected override void CreateChildElements()
Overrides
CreateTableElement(RadVirtualGridElement, VirtualGridViewInfo)
Creates the table element.
Declaration
protected virtual VirtualGridTableElement CreateTableElement(RadVirtualGridElement virtualGridElement, VirtualGridViewInfo viewInfo)
Parameters
RadVirtualGridElement
virtualGridElement
The virtual grid element. |
VirtualGridViewInfo
viewInfo
The view info. |
Returns
VirtualGridTableElement
|
CutSelection()
Cuts the content of the selected cells.
Declaration
public virtual bool CutSelection()
Returns
System.Boolean
True if the operation was successful, otherwise false. |
DeleteRow(IEnumerable<Int32>, VirtualGridViewInfo)
Deletes the rows specified in the first parameter from the specified view info.
Declaration
public void DeleteRow(IEnumerable<int> rowIndices, VirtualGridViewInfo viewInfo)
Parameters
System.Collections.Generic.IEnumerable<System.Int32>
rowIndices
The indices of the rows to delete. |
VirtualGridViewInfo
viewInfo
The view info from which to delete the rows. |
DeleteSelectedRow()
Deletes the currently selected row.
Declaration
public bool DeleteSelectedRow()
Returns
System.Boolean
True if the operations is successful, otherwise false. |
DisposeManagedResources()
Disposes the managed resources.
Declaration
protected override void DisposeManagedResources()
Overrides
DpiScaleChanged(SizeF)
Fires when the DPI scale is changed.
Declaration
public override void DpiScaleChanged(SizeF scaleFactor)
Parameters
System.Drawing.SizeF
scaleFactor
The scale factor. |
Overrides
EndEdit()
Ends the editing process and tries to commit any changes made to the edit value. Returns a value indicating whether the operation succeeded.
Declaration
public virtual bool EndEdit()
Returns
System.Boolean
Returns true if the operation is successful. Returns false if the operation is not successful e.g. validation fails or the grid was not in edit mode. |
EndUpdate()
Resumes layout updates.
Declaration
public void EndUpdate()
EnsureCellVisible(Int32, Int32)
Ensures the cell defined by the row and column indices is visible in the current view.
Declaration
public void EnsureCellVisible(int rowIndex, int columnIndex)
Parameters
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
EnsureCellVisible(Int32, Int32, VirtualGridTableElement)
Ensures the cell defined by the row and column indices is visible in the current view.
Declaration
public void EnsureCellVisible(int rowIndex, int columnIndex, VirtualGridTableElement tableElement)
Parameters
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
VirtualGridTableElement
tableElement
The table element of the row. |
EnsureCellVisible(Int32, Int32, VirtualGridViewInfo)
Ensures the cell defined by the row and column indices is visible in the current view.
Declaration
public void EnsureCellVisible(int rowIndex, int columnIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
VirtualGridViewInfo
viewInfo
The view info of the cell. |
EnsureRowVisible(Int32)
Ensures the row at the specified row index is visible in the current view.
Declaration
public void EnsureRowVisible(int rowIndex)
Parameters
System.Int32
rowIndex
The index of the row. |
EnsureRowVisible(Int32, VirtualGridTableElement)
Ensures the row at the specified row index is visible in the current view.
Declaration
public void EnsureRowVisible(int rowIndex, VirtualGridTableElement tableElement)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridTableElement
tableElement
The table element of the row. |
EnsureRowVisible(Int32, VirtualGridViewInfo)
Ensures the row at the specified row index is visible in the current view.
Declaration
public void EnsureRowVisible(int rowIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridViewInfo
viewInfo
The view info of the row. |
ExpandRow(Int32)
Expands the specified row.
Declaration
public bool ExpandRow(int rowIndex)
Parameters
System.Int32
rowIndex
The row index to expand. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
FindCellElement(Int32, Int32, VirtualGridViewInfo)
Attempts to find a visual cell element that represents the data on the specified row and column indices.
Declaration
public VirtualGridCellElement FindCellElement(int rowIndex, int columnIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
VirtualGridViewInfo
viewInfo
The view info of the cell. |
Returns
VirtualGridCellElement
The cell element if it is visible, otherwise null. |
GetCellElement(Int32, Int32, VirtualGridTableElement)
Gets the cell element for the specified row and column indices and view info.
Declaration
public VirtualGridCellElement GetCellElement(int rowIndex, int columnIndex, VirtualGridTableElement tableElement)
Parameters
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
VirtualGridTableElement
tableElement
The table element of the cell. |
Returns
VirtualGridCellElement
The cell element, if found, otherwise false. |
GetCellElement(Int32, Int32, VirtualGridViewInfo)
Gets the cell element for the specified row and column indices and view info.
Declaration
public VirtualGridCellElement GetCellElement(int rowIndex, int columnIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
VirtualGridViewInfo
viewInfo
The view info of the cell. |
Returns
VirtualGridCellElement
The cell element, if found, otherwise false. |
GetColumnScrollOffset(Int32, VirtualGridTableElement)
Gets the scroll offset from the beginning of the columns in the specified view to the left edge of the specified column.
Declaration
public int GetColumnScrollOffset(int columnIndex, VirtualGridTableElement tableElement)
Parameters
System.Int32
columnIndex
The index of the column. |
VirtualGridTableElement
tableElement
The table element of the column. |
Returns
System.Int32
The distance to the column. |
GetColumnScrollOffset(Int32, VirtualGridViewInfo)
Gets the scroll offset from the beginning of the columns in the specified view to the left edge of the specified column.
Declaration
public int GetColumnScrollOffset(int columnIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
columnIndex
The index of the column. |
VirtualGridViewInfo
viewInfo
The view info of the column. |
Returns
System.Int32
The distance to the column. |
GetColumnWidth(Int32)
Gets the height of the column at the given column index.
Declaration
public int GetColumnWidth(int columnIndex)
Parameters
System.Int32
columnIndex
The index of the column. |
Returns
System.Int32
The height of the column. |
GetDefaultEditor(Object)
Gets an editor based on a cell value. Used when column data types are not defined.
Declaration
protected virtual IInputEditor GetDefaultEditor(object value)
Parameters
System.Object
value
The value of the cell. |
Returns
IInputEditor
The editor to be used for editing the specified value. |
GetEditor(Type)
Gets an editor based on the column data type.
Declaration
protected virtual IInputEditor GetEditor(Type dataType)
Parameters
System.Type
dataType
The data type of the column. |
Returns
IInputEditor
The editor to be used for editing the specified data type. |
GetRowElement(Int32, VirtualGridTableElement)
Gets the row element for the specified row index and view info.
Declaration
public VirtualGridRowElement GetRowElement(int rowIndex, VirtualGridTableElement tableElement)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridTableElement
tableElement
The table element of the row. |
Returns
VirtualGridRowElement
The row element displaying the data for the row, if found, otherwise null. |
GetRowElement(Int32, VirtualGridViewInfo)
Gets the row element for the specified row index and view info.
Declaration
public VirtualGridRowElement GetRowElement(int rowIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridViewInfo
viewInfo
The view info of the row. |
Returns
VirtualGridRowElement
The row element displaying the data for the row, if found, otherwise null. |
GetRowHeight(Int32)
Gets the height of the row at the given row index.
Declaration
public int GetRowHeight(int rowIndex)
Parameters
System.Int32
rowIndex
The index of the row. |
Returns
System.Int32
The height of the row. |
GetRowScrollOffset(Int32, VirtualGridTableElement)
Gets the scroll offset from the beginning of the rows in the specified view to the top edge of the specified row.
Declaration
public int GetRowScrollOffset(int rowIndex, VirtualGridTableElement tableElement)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridTableElement
tableElement
The table element of the row. |
Returns
System.Int32
The distance to the row. |
GetRowScrollOffset(Int32, VirtualGridViewInfo)
Gets the scroll offset from the beginning of the rows in the specified view to the top edge of the specified row.
Declaration
public int GetRowScrollOffset(int rowIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridViewInfo
viewInfo
The view info of the row. |
Returns
System.Int32
The distance to the row. |
GetTableElement(VirtualGridViewInfo)
Gets the table element displaying the info of the specified view info..
Declaration
public VirtualGridTableElement GetTableElement(VirtualGridViewInfo viewInfo)
Parameters
VirtualGridViewInfo
viewInfo
The view info. |
Returns
VirtualGridTableElement
The table element, if found, otherwise null. |
InitializeEditor(IInputEditor, VirtualGridCellElement)
Initializes the editor for editing. Allows settings of the editor to be modified. Fires the CellEditorInitialized event.
Declaration
protected virtual void InitializeEditor(IInputEditor activeEditor, VirtualGridCellElement cell)
Parameters
IInputEditor
activeEditor
The editor that is being initialized. |
VirtualGridCellElement
cell
The cell that will be edited. |
IsColumnPinned(Int32)
Returns a value indicating whether the specified column is pinned.
Declaration
public bool IsColumnPinned(int columnIndex)
Parameters
System.Int32
columnIndex
The index of the column. |
Returns
System.Boolean
True if the column is pinned at left or right, otherwise false. |
IsRowExpanded(Int32)
Returns a value indicating whether the specified row is expanded.
Declaration
public bool IsRowExpanded(int rowIndex)
Parameters
System.Int32
rowIndex
The index of the row. |
Returns
System.Boolean
True if the row is expanded, otherwise false. |
IsRowPinned(Int32)
Returns a value indicating whether the specified row is pinned.
Declaration
public bool IsRowPinned(int rowIndex)
Parameters
System.Int32
rowIndex
The index of the row. |
Returns
System.Boolean
True if the row is pinned at top or bottom, otherwise false. |
MoveCurrent(Int32, Int32, Boolean)
Moves the current cell to the one defined by the row and column indices.
Declaration
public bool MoveCurrent(int rowOffset, int columnOffset, bool keepSelection)
Parameters
System.Int32
rowOffset
The new current cell row index. |
System.Int32
columnOffset
The new current cell column index. |
System.Boolean
keepSelection
Determines if the current selection should be kept or discarded. |
Returns
System.Boolean
|
MoveCurrentDown(Boolean)
Moves the current cell to the one below its current position.
Declaration
public bool MoveCurrentDown(bool keepSelection)
Parameters
System.Boolean
keepSelection
Determines if the current selection should be kept or discarded. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
MoveCurrentLeft(Boolean)
Moves the current cell to the left of its current position.
Declaration
public bool MoveCurrentLeft(bool keepSelection)
Parameters
System.Boolean
keepSelection
Determines if the current selection should be kept or discarded. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
MoveCurrentRight(Boolean)
Moves the current cell to the right of its current position.
Declaration
public bool MoveCurrentRight(bool keepSelection)
Parameters
System.Boolean
keepSelection
Determines if the current selection should be kept or discarded. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
MoveCurrentUp(Boolean)
Moves the current cell to the one above its current position.
Declaration
public bool MoveCurrentUp(bool keepSelection)
Parameters
System.Boolean
keepSelection
Determines if the current selection should be kept or discarded. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
OnCellClick(VirtualGridCellElementEventArgs)
Raises the CellClick event.
Declaration
protected virtual void OnCellClick(VirtualGridCellElementEventArgs args)
Parameters
VirtualGridCellElementEventArgs
args
The VirtualGridCellElementEventArgs instance containing the event data. |
OnCellDoubleClick(VirtualGridCellElementEventArgs)
Raises the CellDoubleClick event.
Declaration
protected virtual void OnCellDoubleClick(VirtualGridCellElementEventArgs args)
Parameters
VirtualGridCellElementEventArgs
args
The VirtualGridCellElementEventArgs instance containing the event data. |
OnCellEditorInitialized(VirtualGridCellEditorInitializedEventArgs)
Raises the CellEditorInitialized event.
Declaration
protected virtual void OnCellEditorInitialized(VirtualGridCellEditorInitializedEventArgs args)
Parameters
VirtualGridCellEditorInitializedEventArgs
args
The VirtualGridCellEditorInitializedEventArgs instance containing the event data. |
OnCellFormatting(VirtualGridCellElementEventArgs)
Raises the CellFormatting event.
Declaration
protected virtual void OnCellFormatting(VirtualGridCellElementEventArgs args)
Parameters
VirtualGridCellElementEventArgs
args
The VirtualGridCellElementEventArgs instance containing the event data. |
OnCellMouseMove(VirtualGridCellElementMouseEventArgs)
Raises the CellMouseMove event.
Declaration
protected virtual void OnCellMouseMove(VirtualGridCellElementMouseEventArgs args)
Parameters
VirtualGridCellElementMouseEventArgs
args
The VirtualGridCellElementMouseEventArgs instance containing the event data. |
OnCellPaint(VirtualGridCellElement, IGraphics)
Raises the CellPaint event.
Declaration
protected virtual void OnCellPaint(VirtualGridCellElement cell, IGraphics g)
Parameters
VirtualGridCellElement
cell
The cell. |
IGraphics
g
The g. |
OnCellValidating(VirtualGridCellValidatingEventArgs)
Raises the CellValidating event.
Declaration
protected virtual void OnCellValidating(VirtualGridCellValidatingEventArgs args)
Parameters
VirtualGridCellValidatingEventArgs
args
The VirtualGridCellValidatingEventArgs instance containing the event data. |
OnCellValueNeeded(VirtualGridCellValueNeededEventArgs)
Fires the CellValueNeeded event.
Declaration
protected virtual void OnCellValueNeeded(VirtualGridCellValueNeededEventArgs args)
Parameters
VirtualGridCellValueNeededEventArgs
args
The event arguments. |
OnCellValuePushed(VirtualGridCellValuePushedEventArgs)
Raises the CellValuePushed event.
Declaration
protected virtual void OnCellValuePushed(VirtualGridCellValuePushedEventArgs args)
Parameters
VirtualGridCellValuePushedEventArgs
args
The VirtualGridCellValuePushedEventArgs instance containing the event data. |
OnColumnWidthChanged(VirtualGridColumnEventArgs)
Raises the ColumnWidthChanged event.
Declaration
protected virtual void OnColumnWidthChanged(VirtualGridColumnEventArgs args)
Parameters
VirtualGridColumnEventArgs
args
The VirtualGridColumnEventArgs instance containing the event data. |
OnColumnWidthChanging(VirtualGridColumnWidthChangingEventArgs)
Raises the ColumnWidthChanging event.
Declaration
protected virtual bool OnColumnWidthChanging(VirtualGridColumnWidthChangingEventArgs args)
Parameters
VirtualGridColumnWidthChangingEventArgs
args
The VirtualGridColumnWidthChangingEventArgs instance containing the event data. |
Returns
System.Boolean
|
OnContextMenuOpening(VirtualGridContextMenuOpeningEventArgs)
Raises the ContextMenuOpening event.
Declaration
protected virtual bool OnContextMenuOpening(VirtualGridContextMenuOpeningEventArgs args)
Parameters
VirtualGridContextMenuOpeningEventArgs
args
The VirtualGridContextMenuOpeningEventArgs instance containing the event data. |
Returns
System.Boolean
|
OnCopying(VirtualGridClipboardEventArgs)
Raises the Copying event.
Declaration
protected virtual void OnCopying(VirtualGridClipboardEventArgs args)
Parameters
VirtualGridClipboardEventArgs
args
The VirtualGridClipboardEventArgs instance containing the event data. |
OnCreateCellElement(VirtualGridCreateCellEventArgs)
Raises the CreateCellElement event.
Declaration
protected virtual void OnCreateCellElement(VirtualGridCreateCellEventArgs e)
Parameters
VirtualGridCreateCellEventArgs
e
The VirtualGridCreateCellEventArgs instance containing the event data. |
OnCreateRowElement(VirtualGridCreateRowEventArgs)
Raises the CreateRowElement event.
Declaration
protected virtual void OnCreateRowElement(VirtualGridCreateRowEventArgs e)
Parameters
VirtualGridCreateRowEventArgs
e
The VirtualGridCreateRowEventArgs instance containing the event data. |
OnCurrentCellChanged(EventArgs)
Raises the CurrentCellChanged event.
Declaration
protected virtual void OnCurrentCellChanged(EventArgs e)
Parameters
System.EventArgs
e
The System.EventArgs instance containing the event data. |
OnCurrentCellChanging(VirtualGridCellInfo)
Raises the CurrentCellChanging event.
Declaration
protected virtual bool OnCurrentCellChanging(VirtualGridCellInfo cellInfo)
Parameters
VirtualGridCellInfo
cellInfo
The cell info. |
Returns
System.Boolean
|
OnEditorRequired(VirtualGridEditorRequiredEventArgs)
Raises the EditorRequired event.
Declaration
protected virtual void OnEditorRequired(VirtualGridEditorRequiredEventArgs args)
Parameters
VirtualGridEditorRequiredEventArgs
args
The VirtualGridEditorRequiredEventArgs instance containing the event data. |
OnFilterDescriptorsChanged(VirtualGridViewInfo)
Raises the FilterDescriptorsChanged event.
Declaration
protected virtual void OnFilterDescriptorsChanged(VirtualGridViewInfo viewInfo)
Parameters
VirtualGridViewInfo
viewInfo
The view information. |
OnPageIndexChanged(VirtualGridEventArgs)
Raises the PageIndexChanged event.
Declaration
protected virtual void OnPageIndexChanged(VirtualGridEventArgs args)
Parameters
VirtualGridEventArgs
args
The VirtualGridEventArgs instance containing the event data. |
OnPageIndexChanging(VirtualGridPageChangingEventArgs)
Raises the PageIndexChanging event.
Declaration
protected virtual void OnPageIndexChanging(VirtualGridPageChangingEventArgs args)
Parameters
VirtualGridPageChangingEventArgs
args
The VirtualGridPageChangingEventArgs instance containing the event data. |
OnPasting(VirtualGridClipboardEventArgs)
Raises the Pasting event.
Declaration
protected virtual void OnPasting(VirtualGridClipboardEventArgs args)
Parameters
VirtualGridClipboardEventArgs
args
The VirtualGridClipboardEventArgs instance containing the event data. |
OnQueryHasChildRows(Int32, VirtualGridViewInfo)
Raises the QueryHasChildRows event.
Declaration
protected virtual bool OnQueryHasChildRows(int rowIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Int32
rowIndex
The index of the row. |
VirtualGridViewInfo
viewInfo
The view info of the row. |
Returns
System.Boolean
|
OnRowCollapsed(VirtualGridRowExpandedEventArgs)
Raises the RowCollapsed event.
Declaration
protected virtual void OnRowCollapsed(VirtualGridRowExpandedEventArgs args)
Parameters
VirtualGridRowExpandedEventArgs
args
The VirtualGridRowExpandedEventArgs instance containing the event data. |
OnRowCollapsing(VirtualGridRowExpandingEventArgs)
Raises the RowCollapsing event.
Declaration
protected virtual void OnRowCollapsing(VirtualGridRowExpandingEventArgs args)
Parameters
VirtualGridRowExpandingEventArgs
args
The VirtualGridRowExpandingEventArgs instance containing the event data. |
OnRowExpanded(VirtualGridRowExpandedEventArgs)
Raises the RowExpanded event.
Declaration
protected virtual void OnRowExpanded(VirtualGridRowExpandedEventArgs args)
Parameters
VirtualGridRowExpandedEventArgs
args
The VirtualGridRowExpandedEventArgs instance containing the event data. |
OnRowExpanding(VirtualGridRowExpandingEventArgs)
Raises the RowExpanding event.
Declaration
protected virtual void OnRowExpanding(VirtualGridRowExpandingEventArgs args)
Parameters
VirtualGridRowExpandingEventArgs
args
The VirtualGridRowExpandingEventArgs instance containing the event data. |
OnRowFormatting(VirtualGridRowElementEventArgs)
Fires the RowFormatting event.
Declaration
protected virtual void OnRowFormatting(VirtualGridRowElementEventArgs args)
Parameters
VirtualGridRowElementEventArgs
args
The VirtualGridRowElementEventArgs instance containing the event data. |
OnRowHeightChanged(VirtualGridRowEventArgs)
Raises the RowHeightChanged event.
Declaration
protected virtual void OnRowHeightChanged(VirtualGridRowEventArgs args)
Parameters
VirtualGridRowEventArgs
args
The VirtualGridRowEventArgs instance containing the event data. |
OnRowHeightChanging(VirtualGridRowHeightChangingEventArgs)
Raises the RowHeightChanging event.
Declaration
protected virtual bool OnRowHeightChanging(VirtualGridRowHeightChangingEventArgs args)
Parameters
VirtualGridRowHeightChangingEventArgs
args
The VirtualGridRowHeightChangingEventArgs instance containing the event data. |
Returns
System.Boolean
|
OnRowPaint(VirtualGridRowElement, IGraphics)
Raises the RowPaint event.
Declaration
protected virtual void OnRowPaint(VirtualGridRowElement row, IGraphics g)
Parameters
VirtualGridRowElement
row
The row. |
IGraphics
g
The g. |
OnRowValidated(VirtualGridRowEventArgs)
Raises the RowValidated event.
Declaration
protected virtual void OnRowValidated(VirtualGridRowEventArgs e)
Parameters
VirtualGridRowEventArgs
e
The VirtualGridRowEventArgs instance containing the event data. |
OnRowValidating(VirtualGridRowValidatingEventArgs)
Raises the RowValidating event.
Declaration
protected virtual void OnRowValidating(VirtualGridRowValidatingEventArgs e)
Parameters
VirtualGridRowValidatingEventArgs
e
The VirtualGridRowValidatingEventArgs instance containing the event data. |
OnSelectionChanged(Object, EventArgs)
Raises the SelectionChanged event.
Declaration
protected virtual void OnSelectionChanged(object sender, EventArgs e)
Parameters
System.Object
sender
The sender. |
System.EventArgs
e
The System.EventArgs instance containing the event data. |
OnSelectionChanging(Object, VirtualGridSelectionChangingEventArgs)
Raises the SelectionChanging event.
Declaration
protected virtual void OnSelectionChanging(object sender, VirtualGridSelectionChangingEventArgs e)
Parameters
System.Object
sender
The sender. |
VirtualGridSelectionChangingEventArgs
e
The VirtualGridSelectionChangingEventArgs instance containing the event data. |
OnSortDescriptorsChanged(VirtualGridViewInfo)
Raises the SortDescriptorsChanged event.
Declaration
protected virtual void OnSortDescriptorsChanged(VirtualGridViewInfo viewInfo)
Parameters
VirtualGridViewInfo
viewInfo
The view info. |
OnUserDeletedRow(VirtualGridRowsEventArgs)
Raises the UserDeletedRow event.
Declaration
protected virtual void OnUserDeletedRow(VirtualGridRowsEventArgs e)
Parameters
VirtualGridRowsEventArgs
e
The VirtualGridRowsEventArgs instance containing the event data. |
OnValueChanged(Object, EventArgs)
Raises the ValueChanged event.
Declaration
protected virtual void OnValueChanged(object sender, EventArgs e)
Parameters
System.Object
sender
The source of the event. |
System.EventArgs
e
The System.EventArgs instance containing the event data. |
OnValueChanging(Object, ValueChangingEventArgs)
Raises the ValueChanging event.
Declaration
protected virtual void OnValueChanging(object sender, ValueChangingEventArgs e)
Parameters
System.Object
sender
The source of the event. |
ValueChangingEventArgs
e
The ValueChangingEventArgs instance containing the event data. |
OnViewInfoPropertyChanged(VirtualGridViewInfo, String)
Raises the ViewInfoPropertyChanged event.
Declaration
protected virtual void OnViewInfoPropertyChanged(VirtualGridViewInfo viewInfo, string propertyName)
Parameters
VirtualGridViewInfo
viewInfo
The view info. |
System.String
propertyName
Name of the property. |
Paste()
Pastes the content of the clipboard into starting from the current cell and going on until either the available cells or the clipboard content ends.
Declaration
public virtual bool Paste()
Returns
System.Boolean
True if the operation is successful, otherwise false. |
ProcessContent(String, Int32, Int32, Int32, Int32, VirtualGridViewInfo, Boolean, Boolean)
Processes the content of the cells in the specified region and returns a string to be places in the clipboard.
Declaration
protected virtual string ProcessContent(string format, int startRow, int startColumn, int endRow, int endColumn, VirtualGridViewInfo viewInfo, bool selectedOnly, bool cut)
Parameters
System.String
format
The format of the data that should be returned. |
System.Int32
startRow
The index of the row where the content processing should start. |
System.Int32
startColumn
The index of the column where the content processing should start. |
System.Int32
endRow
The index of the row where the content processing should end. |
System.Int32
endColumn
The index of the column where the content processing should end. |
VirtualGridViewInfo
viewInfo
The view info of the cell region. |
System.Boolean
selectedOnly
Determines whether only selected cells are processed. |
System.Boolean
cut
Determines whether cell values should be cleared after they are processed. |
Returns
System.String
|
SetCellValue(Object, Int32, Int32, VirtualGridViewInfo)
Sets the value of a given cell to the specified value.
Declaration
public void SetCellValue(object value, int rowIndex, int columnIndex, VirtualGridViewInfo viewInfo)
Parameters
System.Object
value
The new value for the cell. |
System.Int32
rowIndex
The row index of the cell. |
System.Int32
columnIndex
The column index of the cell. |
VirtualGridViewInfo
viewInfo
The view info of the cell. |
SetColumnPinPosition(Int32, PinnedColumnPosition)
Sets the pin position of the specified column.
Declaration
public void SetColumnPinPosition(int columnIndex, PinnedColumnPosition pinPosition)
Parameters
System.Int32
columnIndex
The index of the column. |
PinnedColumnPosition
pinPosition
The new pin position. |
SetColumnWidth(Int32, Int32)
Sets the width of the column at the specified column index in the master view info.
Declaration
public void SetColumnWidth(int columnIndex, int width)
Parameters
System.Int32
columnIndex
The index of the column |
System.Int32
width
The new width of the column. |
SetColumnWidth(Int32, Int32[])
Sets the width of the columns at the specified column indices in the master view info.
Declaration
public void SetColumnWidth(int width, params int[] columnIndices)
Parameters
System.Int32
width
The new width of the columns. |
System.Int32[]
columnIndices
The indices of the columns. |
SetCurrentCell(VirtualGridCellInfo)
Sets the specified cell as the current cell.
Declaration
protected virtual bool SetCurrentCell(VirtualGridCellInfo value)
Parameters
VirtualGridCellInfo
value
The cell to mark as current. |
Returns
System.Boolean
True if the operation is successful, otherwise false. |
SetRowHeight(Int32, Int32)
Sets the height of the row at the specified row index in the master view info.
Declaration
public void SetRowHeight(int rowIndex, int height)
Parameters
System.Int32
rowIndex
The index of the row. |
System.Int32
height
The new height of the row. |
SetRowHeight(Int32, Int32[])
Sets the height of the rows at the specified row indices in the master view info.
Declaration
public void SetRowHeight(int height, params int[] rowIndices)
Parameters
System.Int32
height
The new height of the rows. |
System.Int32[]
rowIndices
The indices of the rows. |
SetRowPinPosition(Int32, PinnedRowPosition)
Sets the pin position of the specified row.
Declaration
public void SetRowPinPosition(int rowIndex, PinnedRowPosition pinPosition)
Parameters
System.Int32
rowIndex
The index of the row. |
PinnedRowPosition
pinPosition
The new pin position. |
Events
CellClick
Occurs when a cell is clicked.
Declaration
public event VirtualGridCellElementEventHandler CellClick
Event Type
VirtualGridCellElementEventHandler
|
CellDoubleClick
Occurs when a cell is double clicked.
Declaration
public event EventHandler CellDoubleClick
Event Type
System.EventHandler
|
CellEditorInitialized
Occurs when the editor of a cell is initialized.
Declaration
public event VirtualGridCellEditorInitializedEventHandler CellEditorInitialized
Event Type
VirtualGridCellEditorInitializedEventHandler
|
CellFormatting
Occurs when a cell is updated and needs formatting.
Declaration
public event VirtualGridCellElementEventHandler CellFormatting
Event Type
VirtualGridCellElementEventHandler
|
CellMouseMove
Occurs when the mouse is moved over a cell.
Declaration
public event VirtualGridCellElementMouseEventHandler CellMouseMove
Event Type
VirtualGridCellElementMouseEventHandler
|
CellPaint
Occurs after a cell is painted allowing users to draw on top of it.
Declaration
public event VirtualGridCellPaintEventHandler CellPaint
Event Type
VirtualGridCellPaintEventHandler
|
CellValidating
Occurs before a cell is validated.
Declaration
public event VirtualGridCellValidatingEventHandler CellValidating
Event Type
VirtualGridCellValidatingEventHandler
|
CellValueNeeded
Occurs when a cell is displayed and its content should be updated.
Declaration
public event VirtualGridCellValueNeededEventHandler CellValueNeeded
Event Type
VirtualGridCellValueNeededEventHandler
|
CellValuePushed
Occurs when a cell value is edited and should be stored in the data source.
Declaration
public event VirtualGridCellValuePushedEventHandler CellValuePushed
Event Type
VirtualGridCellValuePushedEventHandler
|
ColumnWidthChanged
Occurs after the width of a column changes.
Declaration
public event VirtualGridColumnEventHandler ColumnWidthChanged
Event Type
VirtualGridColumnEventHandler
|
ColumnWidthChanging
Occurs before the width of a column changes.
Declaration
public event VirtualGridColumnWidthChangingEventHandler ColumnWidthChanging
Event Type
VirtualGridColumnWidthChangingEventHandler
|
ContextMenuOpening
Occurs when the context menu is about to be opened.
Declaration
public event VirtualGridContextMenuOpeningEventHandler ContextMenuOpening
Event Type
VirtualGridContextMenuOpeningEventHandler
|
Copying
Occurs when the content of cell(s) is copied. Allows users to modify the operation or content.
Declaration
public event VirtualGridClipboardEventHandler Copying
Event Type
VirtualGridClipboardEventHandler
|
CreateCellElement
Occurs when a new cell element has to be created.
Declaration
public event VirtualGridCreateCellEventHandler CreateCellElement
Event Type
VirtualGridCreateCellEventHandler
|
CreateRowElement
Occurs when a new row element has to be created.
Declaration
public event VirtualGridCreateRowEventHandler CreateRowElement
Event Type
VirtualGridCreateRowEventHandler
|
CurrentCellChanged
Occurs after the current cell changes.
Declaration
public event EventHandler CurrentCellChanged
Event Type
System.EventHandler
|
CurrentCellChanging
Occurs before the current cell changes.
Declaration
public event VirtualGridCellInfoCancelEventHandler CurrentCellChanging
Event Type
VirtualGridCellInfoCancelEventHandler
|
EditorRequired
Occurs when an editor for a cell is required.
Declaration
public event VirtualGridEditorRequiredEventHandler EditorRequired
Event Type
VirtualGridEditorRequiredEventHandler
|
FilterDescriptorsChanged
Occurs when the filter descriptors collection changes.
Declaration
public event VirtualGridEventHandler FilterDescriptorsChanged
Event Type
VirtualGridEventHandler
|
PageIndexChanged
Occurs after the current page index changes.
Declaration
public event VirtualGridEventHandler PageIndexChanged
Event Type
VirtualGridEventHandler
|
PageIndexChanging
Occurs before the current page index changes.
Declaration
public event VirtualGridPageChangingEventHandler PageIndexChanging
Event Type
VirtualGridPageChangingEventHandler
|
Pasting
Occurs when the content of cell(s) is about to be pasted. Allows users to modify the operation or content.
Declaration
public event VirtualGridClipboardEventHandler Pasting
Event Type
VirtualGridClipboardEventHandler
|
QueryHasChildRows
Occurs when a row has to determine if it has child rows.
Declaration
public event VirtualGridQueryHasChildRowsEventHandler QueryHasChildRows
Event Type
VirtualGridQueryHasChildRowsEventHandler
|
RowCollapsed
Occurs after a row is collapsed.
Declaration
public event VirtualGridRowExpandedEventHandler RowCollapsed
Event Type
VirtualGridRowExpandedEventHandler
|
RowCollapsing
Occurs before a row is collapsed.
Declaration
public event VirtualGridRowExpandingEventHandler RowCollapsing
Event Type
VirtualGridRowExpandingEventHandler
|
RowExpanded
Occurs after a row is expanded.
Declaration
public event VirtualGridRowExpandedEventHandler RowExpanded
Event Type
VirtualGridRowExpandedEventHandler
|
RowExpanding
Occurs before a row is expanded.
Declaration
public event VirtualGridRowExpandingEventHandler RowExpanding
Event Type
VirtualGridRowExpandingEventHandler
|
RowFormatting
Occurs when a row is updated and needs formatting.
Declaration
public event VirtualGridRowElementEventHandler RowFormatting
Event Type
VirtualGridRowElementEventHandler
|
RowHeightChanged
Occurs after a row height changes.
Declaration
public event VirtualGridRowEventHandler RowHeightChanged
Event Type
VirtualGridRowEventHandler
|
RowHeightChanging
Occurs before a row height changes.
Declaration
public event VirtualGridRowHeightChangingEventHandler RowHeightChanging
Event Type
VirtualGridRowHeightChangingEventHandler
|
RowPaint
Occurs after a row is painted allowing users to draw on top of it.
Declaration
public event VirtualGridRowPaintEventHandler RowPaint
Event Type
VirtualGridRowPaintEventHandler
|
RowValidated
Occurs after a row is validated.
Declaration
public event VirtualGridRowEventHandler RowValidated
Event Type
VirtualGridRowEventHandler
|
RowValidating
Occurs before a row is validated.
Declaration
public event VirtualGridRowValidatingEventHandler RowValidating
Event Type
VirtualGridRowValidatingEventHandler
|
SelectionChanged
Occurs after the selection changes.
Declaration
public event EventHandler SelectionChanged
Event Type
System.EventHandler
|
SelectionChanging
Occurs before the selection changes.
Declaration
public event VirtualGridSelectionChangingEventHandler SelectionChanging
Event Type
VirtualGridSelectionChangingEventHandler
|
SortDescriptorsChanged
Occurs when the sort descriptors collection changes.
Declaration
public event VirtualGridEventHandler SortDescriptorsChanged
Event Type
VirtualGridEventHandler
|
UserAddedRow
Occurs when a user adds a row.
Declaration
public event VirtualGridNewRowEventHandler UserAddedRow
Event Type
VirtualGridNewRowEventHandler
|
UserDeletedRow
Occurs when a user deletes a row.
Declaration
public event VirtualGridRowsEventHandler UserDeletedRow
Event Type
VirtualGridRowsEventHandler
|
ValueChanged
Occurs after the value of a cell has been changed.
Declaration
public event EventHandler ValueChanged
Event Type
System.EventHandler
|
ValueChanging
Occurs before the value of a cell is changed.
Declaration
public event ValueChangingEventHandler ValueChanging
Event Type
ValueChangingEventHandler
|
ViewInfoPropertyChanged
Occurs when a property of the view info changes.
Declaration
public event VirtualGridViewInfoPropertyChangedEventHandler ViewInfoPropertyChanged
Event Type
VirtualGridViewInfoPropertyChangedEventHandler
|