GridControl | The GridControl class represents and embodies an Objective Grid for .NET grid control. The GridControl custom control is added to the Visual Studio toolbox when Objective Grid for .NET is installed. When a GridControl is dragged onto a Windows Form, an instance of the GridControl class is created. The GridControl class contains a rich public interface, a rich set of public events, a number of properties, and a customizable virtual method interface. |
Cell | The Cell class represents a single cell in the grid. A cell is referenced by a row offset and a column offset. The Cell class contains properties for the cell's row, column, text, and style. |
Range | The Range class represents a range of cells in the grid. The Range class can be used for operations that apply to a group of cells. |
Style | The Style class is central to formatting cells in the grid. A style object can be seen as an object that completely defines a cell. This means that the style object has all the information necessary for the grid object to draw the cell and manage its interaction with users. This information includes the font used to draw the cell, the color of the cell's interior, the size of the font, the value displayed, and the type of control in the cell. Style objects for each cell are stored internally by the grid. The format of a grid cell can be changed programmatically through the manipulation of the style property of the cell. |
Param | The Param (short for Parameter) class stores all data necessary for persisting the state of a grid object. Parameter objects can be stored in documents and serialized, or used as members of other classes. Parameter objects can also be shared between grid objects. |
Method | Description |
---|---|
ApplyNewStyle | Applies a new style stored in this cell object. |
ClearStyle | Clears the embedded Style object. |
ClearValue | Clears only the value. |
CopyCell | Copies the contents of another cell into this cell. |
CopyCells | Copies a range of cells. |
CopyStyle | Copies the new Style over the one stored in this cell object. |
ExcludeStyle | Attributes that are included in the source style are removed from the destination style. |
MoveCell | Command for moving a cell. Cell references in formula expressions are adjusted if they depend on a moved cell. |
MoveCells | Command for moving cells. Cell references in formula expressions are adjusted if they depend on cells in the moved range. |
OverrideStyle | Override the current style in this cell object. |
ScrollInView | Overloaded. Scrolls the grid so that this cell is in view. |
Select | Overloaded. Selects or deselects this cell. |
Property | Description |
---|---|
Col | Gets the cell's column index. |
Formula | Returns either the text value or formula for the cell. |
IsCurrent | Determines if the cell is currently selected. |
Row | Gets the cell's row index. |
Style | Gets a reference to this cell's embedded Style object. |
Method | Description |
---|---|
Cell | Creates a range referencing one cell |
Cells | Creates an arbitrary range of cells |
Col | Creates a range of one column |
Cols | Creates a range of columns |
FromLTRB | Creates a range from left, top, right, and bottom row and column indexes |
IntersectRange | Determines if two ranges intersect |
InvalidRange | Returns an empty range |
Row | Returns a range consisting of one row |
Rows | Returns a range of the specified rows |
Table | Creates a range that references an entire table |
UnionRange | Calculates the union of two ranges |
Clone | Creates a copy of this Range |
Equals | Determines if this range is equal to another range |
ExpandRange | Sets the range based on the top, left corner of the range, and the number of rows and columns in the range. |
GetFirstCell | Gets the first cell in a range |
GetHashCode | Calculates the hash code for this range |
GetNextCell | Overloaded. Gets the next cell in a range in row order |
InsertCols | Inserts columns into a range at a specified starting location |
InsertRows | Inserts rows into the range at the specified location |
IntersectRange | Determines if this range intersects with a specified range |
IsCellInRange | Returns true if and only if a specified cell coordinate is within this range |
Property | Description |
---|---|
Bottom | Gets the bottom row in the range |
Height | Gets the height, in rows, of the range |
IsCells | Returns true if this is an arbitrary range of cells |
IsCols | Returns true if this is a range of columns |
IsRows | Returns true if this is a range of rows |
IsTable | Returns true if this range references an entire table |
IsValid | Returns true if and only if this range is valid |
Left | Gets the leftmost column in the range |
RangeType | Gets the type of range as a RangeType enumeration |
Right | Gets the rightmost column in the range |
Top | Gets the topmost row in the range |
Width | Gets the width, in columns, of the range |
Method | Description |
---|---|
Clone | Creates a new copy of an existing Style object. |
Dispose | Disposes of the resources used by a Style object. |
Free | Frees the resources used by a Style object. |
SetDefaults | Sets the cell's properties to default values. |
Property | Description |
---|---|
AllowEnter | Gets or sets the allow enter property. |
AutoSize | Gets or sets the auto size property. |
Borders | Gets or sets the appearance of the cell borders. |
ChoiceList | Gets or sets choice list values. |
Control | Gets or sets the embedded control type. |
Draw3dFrame | Gets or sets the 3D effect of the cell. |
EllipseType | Gets or sets the type of ellipsis used when the text is longer than the cell. |
Enabled | Gets or sets the enabled state for the cell. |
FloatCell | Gets or sets the float cell property. |
FloodCell | Gets or sets the flood cell property. |
HorzAlign | Gets or sets the cell's horizontal alignment. |
IncludeAllowEnter | Gets or sets the state of the AllowEnter property. |
IncludeAutoSize | Gets or sets the state of the AutoSize property. |
IncludeBorders | Gets or sets the state of the Borders property. |
IncludeChoiceList | Gets or sets the state of the ChoiceList property. |
IncludeControl | Gets or sets the state of the Control property. |
IncludeDraw3dFrame | Gets or sets the state of the Draw3dFrame property. |
IncludeEnabled | Gets or sets the state of the Enabled property. |
IncludeFloatCell | Gets or sets the state of the FloatCell property. |
IncludeFloodCell | Gets or sets the state of the FloodCell property. |
IncludeHorzAlign | Gets or sets the state of the HorzAlign property. |
IncludeInterior | Gets or sets the state of the Interior property. |
IncludeItemData | Gets or sets the state of the ItemData property. |
IncludeMaxLength | Gets or sets the state of the MaxLength property. |
IncludeMergeCell | Gets or sets the state of the MergeCell property. |
IncludeReadOnly | Gets or sets the state of the ReadOnly property. |
IncludeTextColor | Gets or sets the state of the TextColor property. |
IncludeTextFont | Gets or sets the state of the TextFont property. |
IncludeTriState | Gets or sets the state of the TriState property. |
IncludeUserAttribute | Gets or sets the state of a specific user attribute. |
IncludeValue | Gets or sets the state of the Value property. |
IncludeVertAlign | Gets or sets the state of the VertAlign property. |
IncludeVerticalScroll | Gets or sets the state of the VerticalScroll property. |
IncludeWrapText | Gets or sets the state of the WrapText property. |
InitialValue | Gets or sets the initial value of the spin control. |
Interior | Gets or sets the interior brush. |
ItemData | Gets or sets a pointer to a user defined item data. |
LowerBound | Gets or sets the lower bound of the spin control. |
Mask | Gets or sets a user specified mask string. |
MaxLength | Gets or sets the maximum length of the stored value. |
MergeCell | Gets or sets the cell merge behavior. |
OnlyNumericValues | Gets or sets numeric validation. |
Prompt | Gets or sets the user specified input prompt. |
ReadOnly | Gets or sets the cell's read-only state. |
TextColor | Gets or sets the color of text in a cell. |
TextFont | Gets or sets the cell's text font. |
ToolTip | Gets or sets the string used for the tool tip. |
TriState | Gets or sets the tristate property of the cell. |
TypeOf | Gets or sets the value type. |
UpperBound | Gets or sets the upper bound of the spin control. |
ValidateMessage | Gets or sets the message to be displayed if the Style value is invalid. |
ValidMaximum | Gets or sets the highest valid minimum value. |
ValidMinimum | Gets or sets the lowest valid value. |
Value | Gets or sets the stored value. |
VertAlign | Gets or sets the cell's vertical alignment. |
VerticalScroll | Gets or sets the vertical scroll bar in a cell. |
WrapText | Gets or sets text wrap. |
WrapValue | Gets or sets the Wrap Value property. |
Method | Description |
---|---|
EnableTrackingColWidth | Overloaded. Specifies the options for or disables changing column widths for the end user. |
EnableTrackingRowHeight | Overloaded. Specifies the options for or disables changing row heights for the end user. |
Finalize | Destructor. |
ReInitializeData | Reinitializes the embedded OGData and OGParam objects. |
Property | Description |
---|---|
CellActivationMode | Determines the options for activating/editing the current cell. |
DrawOrder | Gets or sets the drawing order. |
EnableHorizontalSorting | Gets or sets row sorting when double clicked. |
EnableVerticalSorting | Gets or sets column sorting when double clicked. |
ExcelLikeCurrentCell | Gets or sets the default Objective Grid or Excel-like behavior of the current cell. |
ExcelLikeHeaders | Gets or sets the Excel-like behavior of the headers. |
ExcelLikeScrolling | Gets or sets scroll behavior to mimic Excel scroll behavior. |
ExcelLikeSelectionFrame | Gets or sets the option to draw a small frame around the selected range of cells. |
ExpressionDisplayMode | Gets or sets the display of formula expressions in inactive cells. |
HideCurrentCellMode | Gets or sets options for hiding the current cell. |
LockReadOnly | Gets or sets the readonly state for cells in the grid. |
NumberedColHeaders | Gets or sets numbered column headers. |
NumberedRowHeaders | Gets or sets numbered row headers. |
Properties | Gets the OGProperties object associated with the grid. |
Selections | Gets the allowable cell selections for the grid. |
SmartResize | Enable and disable smart resizing. |
SpecialMode | Gets or sets list box behavior. |
TransparentBackground | Gets or sets a transparent background color for cells. |
Method | Description |
---|---|
BeginInit | Implements ISupportInitialize. |
CalcClientColFromPt | Determines the column for the point. |
CalcClientRowFromPt | Determines the row for the point. |
CalcRectFromRowColEx | Overloaded. Computes the window-area for the given range of cells. |
CalcSumOfColWidths | Overloaded. Computes the total width of the given columns. If the total width exceeds nAbortAt, the method aborts and returns the value that is greater than nAbortAt. |
CalcSumOfRowHeights | Overloaded. Computes the total height of the given rows. |
CanClear | Determines if the currently selected range of cells can be cleared. |
CanCopy | Determines if the currently selected range of cells can be copied. |
CanCut | Determines if the currently selected range of cells can be cut. |
CanPaste | Determines if a range of cells on the clipboard can be pasted into the grid. |
CanSelectCurrentCell | Determines if the new current cell can be selected or the old current cell deselected. |
ClearCells | Overloaded. Clears a range of cells. |
ConvertClientCol | Converts the specified column index into a relative index. |
ConvertClientRow | Converts the specified row index into a relative index. |
ConvertCol | Converts the specified column index into an absolute index. |
ConvertRow | Converts the specified row index into an absolute index. |
CopyCells | Overloaded. Copies a range of cells to a specified location in the grid. |
DelayFloatCells | Overloaded. Recalculates floating cells. |
DelayMergeCells | Overloaded. Recalculates merge cells. |
DesignTimeInitialize | Performs some specialized design-time grid initialization. |
EndInit | Implements ISupportInitialize. |
GetColWidth | Gets the column width, in pixels, of the specified column. If it is 0 then the column is hidden. |
GetExpressionRowCol | Gets the expression stored in a particular cell. |
GetFontHeight | Returns the height of the standard-style font in pixels. |
GetFontWidth | Returns the average width of the standard-style font in pixels. |
GetGridRect | Returns the window area for the grid. |
GetRowHeight | Gets the row height, in pixels, of the specified column. If it is 0, the row is hidden. |
GetSelectedCols | Overloaded. Returns an array containing the selected column IDs. |
GetSelectedRows | Overloaded. Returns an array containing the selected row IDs. |
GetValueRowCol | Gets the value stored in a cell. |
Height_DPtoLP | Divides the pixel-value by the value determined through GetFontHeight. |
Height_LPtoDP | Multiplies the logical value with the value determined through GetFontHeight. |
HideCols | Overloaded. Hides the specified columns. |
HideRange | Hides a range of cells. |
HideRows | Overloaded. Hides the specified rows. |
HitTest | Determines the type of information displayed at a window coordinate (pt). |
Initialize | Initializes a GridControl object state at runtime. |
InitParamObject | Initializes the grid parameter object. |
InsertCols | Overloaded. Inserts columns. |
InsertRows | Overloaded. Inserts rows. |
IsActiveCurrentCell | Returns true if the current cell is active. |
IsColHidden | Determines if the specified column is hidden. |
IsCurrentCell | Overloaded. Determines if a current cell is selected or is the specified cell. |
IsRowHidden | Determines if the specified row is hidden. |
LockUpdate | Overloaded. Prevents display of updates until lockUpdate(false) is called. |
MoveCells | Overloaded. Moves a range of cells. |
MoveCols | Overloaded. Moves the specified block of columns to another location. |
MoveCurrentCell | Overloaded. Selects a new current cell based on an offset from the existing current cell. |
MoveRows | Overloaded. Moves the specified block of rows to another location. |
OnClear | Overloaded. Raises the Clear event. |
OnCopy | Raises the Copy event. |
OnCut | Raises the Cut event. |
OnFind | Raises the Find event. |
OnGetStyleRowCol | Raises the GetStyleRowCol event. |
OnPaste | Raises the Paste event. |
OnPrint | Raises the Print event. |
OnPrintPreview | Overloaded. Raises the PrintPreview event. |
OnRedo | Raises the Redo event. |
OnReplace | Raises the Replace event. |
OnUndo | Raises the Undo event. |
RedrawGrid | Overloaded. Redraws the whole grid. |
RedrawRowCol | Overloaded. Redraw the specified range of cells. |
RegisterControl | Registers a .NET control for use as a Objective Grid for .NET cell editor. |
RemoveCols | Overloaded. Removes a block of columns. |
RemoveRows | Overloaded. Removes a block of rows. |
ResetCurrentCell | Overloaded. Deactivates the current cell. |
ScrollCellInView | Overloaded. Scrolls the cell into the view if it is outside the visible area. |
SelectRange | Overloaded. Selects or deselects a range of cells. |
SetColCount | nColsthe number of columns for the grid rFlagsthe RedrawFlags for the operation |
SetColWidth | Overloaded. Sets the column-widths for specific columns in pixels. |
SetCoveredCellsRowCol | Overloaded. Sets the covered cells-range for a cell. |
SetExpressionRowCol | Overloaded. Stores the expression in the specified cell. |
SetFloatCellsMode | Turns on and off the calculation of floating cells in the grid. |
SetGridLineStyle | Set the grid line style. |
SetGridRect | Overloaded. Sets the grid rectangle for the window. |
SetMergeCellsMode | Turns on and off the calculation of merge cells in the grid. |
SetRowCount | Sets the number of rows in the grid. |
SetRowHeight | Overloaded. Sets the row-heights for specific rows in pixels. |
SetStyleRange | Overloaded. Applies cell formatting to the specified range of cells. |
SetValueRange | Overloaded. Sets a range of cells with the specified value. |
TransferCurrentCell | Overloaded. Stores and deactivates the current cell or actualizes the current cell’s contents. |
UseControl | Uses the named CellControl in the grid at the named row and column location. |
Width_DPtoLP | The method divides the pixel-value by the value determined through GetFontWidth. |
Width_LPtoDP | The method multiplies the logical value with the value determined through GetFontWidth. |
Finalize | Destructor. |
UpdateFrozenCols | Overloaded. Updates the window after freezing columns. |
UpdateFrozenRows | Overloaded. Updates the window after freezing rows. |
Event Handler | Description |
---|---|
OnCanceledEditing | Raises the CanceledEditing event. |
OnCancelEditing | Raises the CancelEditing event. |
OnClickedButtonRowCol | Raises the ClickedButtonRowCol event. |
OnCreateControl | Overridden from Panel. |
OnDeleteCell | Raises the DeleteCell event. |
OnDrawGridItem | Raises the DrawGridItem event. |
OnDrawTopLeftBottomRight | Raises the DrawTopLeftBottomRight event. |
OnEndEditing | Raises the EndEditing event. |
OnGridDraw | Raises the GridDraw event. |
OnInitCurrentCell | Raises the InitCurrentCell event. |
OnLButtonClickedRowCol | Raises the LButtonClickedRowCol event. |
OnLButtonDblClkRowCol | Raises the LButtonDblClkRowCol event. |
OnLButtonHitRowCol | Raises the LButtonHitRowCol event. |
OnLeftCell | Raises the LeftCell event. |
OnMButtonClickedRowCol | Raises the MButtonClickedRowCol event. |
OnMButtonDblClkRowCol | Raises the MButtonDblClkRowCol event. |
OnMButtonHitRowCol | Raises the MButtonHitRowCol event. |
OnModifyCell | Raises the ModifyCell event. |
OnMovedCurrentCell | Raises the MovedCurrentCell event. |
OnProcessKeys | Raises the ProcessKeys event. |
OnRButtonClickedRowCol | Raises the RButtonClickedRowCol event. |
OnRButtonDblClkRowCol | Raises the RButtonDblClkRowCol event. |
OnRButtonHitRowCol | Raises the RButtonHitRowCol event. |
OnStartEditing | Raises the StartEditing event. |
OnStoreColWidth | Raises the StoreColWidth event. |
OnStoreCopyCells | Raises the StoreCopyCells event. |
OnStoreDefaultColWidth | Raises the StoreDefaultColWidth event. |
OnStoreDefaultRowHeight | Raises the StoreDefaultRowHeight event. |
OnStoreFrozenCols | Raises the StoreFrozenCols event. |
OnStoreFrozenRows | Raises the StoreFrozenRows event. |
OnStoreHideCol | Raises the StoreHideCol event. |
OnStoreHideRow | Raises the StoreHideRow event. |
OnStoreInsertCols | Raises the StoreInsertCols event. |
OnStoreInsertRows | Raises the StoreInsertRows event. |
OnStoreMoveCols | Raises the StoreMoveCols event. |
OnStoreMoveRows | Raises the StoreMoveRows event. |
OnStoreReadOnly | Raises the StoreReadOnly event. |
OnStoreRemoveCols | Raises the StoreRemoveCols event. |
OnStoreRemoveRows | Raises the StoreRemoveRows event. |
OnStoreRowHeight | Raises the StoreRowHeight event. |
OnStoreStyleRowCol | Raises the StoreStyleRowCol event. |
OnStoreZoom | Raises the StoreZoom event. |
OnValidateCell | Raises the ValidateCell event. |
OnValidating | Overridden from Panel. |
Property | Description |
---|---|
AcclerateArrowKey | Sets scrolling speed with arrow keys. |
AcclerateScrollBars | Sets scrolling speed with scrollbar buttons. |
AutoScroll | Sets auto-scroll mode. |
Cell | Grid cell indexer, which allows a grid Cell object to be obtained. |
CurrentCell | Gets or sets the current grid cell. |
DefaultColWidth | Returns the default value for the column-width in pixels. |
DefaultRowHeight | Returns the default value for the row-height in pixels. |
EnableUndo | Returns true if undo-creation is enabled; false otherwise. |
Features | Returns a reference to the GridFeatures object associated with a particular GridControl object. |
FloatCells | Returns the setting of floating cells: enabled or disabled. |
FrozenCols | Returns the number of frozen columns in the grid. |
FrozenRows | Returns the number of frozen rows. |
HeaderCols | Returns the number of columns to be used as row headers. |
HeaderRows | Returns the number of rows to be used as column headers. |
LeftCol | Returns the leftmost non-frozen column of the view. |
MergeCells | Returns the setting of merging cells: enabled or disabled. |
Param | Returns a pointer to the parameter object. |
Properties | Returns a pointer to the properties object. |
ReadOnly | Returns the read only setting. |
RightToLeft | Overrides Control.RightToLeft. |
TopRow | Returns the index of the topmost scrollable row. |
Zoom | Returns the zooming-factor as a percentage. |
Event | Description |
---|---|
AddCustomComponent | Ensures custom components will be deleted when GridControl is destroyed. |
CanceledEditing | Canceled Editing Event. |
CancelEditing | Cancel Editing Event. |
Clear | Clear Event. |
Click | Occurs when the control is clicked. |
ClickedButtonRowCol | Clicked Button Row/Column Event. |
Copy | Copy Event. |
Cut | Cut Event. |
DeleteCell | Delete Cell Event. |
DrawGridItem | Draw Grid Item Event. |
DrawTopLeftBottomRight | Draw Top, Left, Bottom, Right Event. |
EndEditing | End Editing Event. |
Find | Find Event. |
FreeNativeStyles | Releases any styles created during initialization. |
GetStyleRowCol | Get Style Row Col Event. |
GridBeginPrint | Invoked when printing begins. |
GridBeginPrintPreview | Invoked when print preview begins. |
GridDraw | Grid Draw Event. |
GridEndPrint | Invoked when printing is ending. |
GridEndPrintPreview | Invoked when print preview is ending. |
GridInitialized | Grid Initialized Event. |
GridPrintPage | Invoked as each page is printed. |
GridPrintPreviewPage | Invoked as each page of a print preview is prepared for preview. |
HorizontalScroll | Horizontal Scroll Event. |
InitCurrentCell | Init Current Cell Event. |
KeyDown | Occurs when a key is pressed while the control has focus. |
KeyPress | Occurs when a key is pressed while the control has focus. |
KeyUp | Occurs when a key is released while the control has focus. |
LButtonClickedRowCol | Left Button Clicked Row Column Event. |
LButtonDblClkRowCol | Left Button Double Clicked Row Column Event. |
LButtonHitRowCol | Left Button Hit Row Column Event. |
LeftCell | Left Cell Event. |
MButtonClickedRowCol | Middle Button Clicked Row Column Event. |
MButtonDblClkRowCol | Middle Button Double Clicked Row Column Event. |
MButtonHitRowCol | Middle Button Hit Row Column Event. |
ModifyCell | Modify Cell Event. |
MouseDown | Occurs when the mouse pointer is over the control and a mouse button is pressed. |
MouseMove | Occurs when the mouse pointer is moved over the control. |
MouseUp | Occurs when the mouse pointer is over the control and a mouse button is released. |
MovedCurrentCell | Moved Current Cell Event. |
Paint | Occurs when the control is redrawn. |
Paste | Paste Event. |
Print | Print event invoked from OnPrint. |
PrintPreview | PrintPreview event invoked from OnPrintPreview. |
ProcessKeys | Process Keys Event. |
RButtonClickedRowCol | Right Button Clicked Row Column Event. |
RButtonDblClkRowCol | Right Button Double Clicked Row Column Event. |
RButtonHitRowCol | Right Button Hit Row Column Event. |
Redo | Redo Event. |
Replace | Replace Event. |
StartEditing | Start Editing Event. |
StoreColWidth | Store Column Width Event. |
StoreCopyCells | Store Copy Cells Event. |
StoreDefaultColWidth | Store Default Column Width Event. |
StoreDefaultRowHeight | Store Default Row Height Event. |
StoreFrozenCols | Store Frozen Cells Event. |
StoreFrozenRows | Store Frozen Rows Event. |
StoreHideCol | Store Hide Column Event. |
StoreHideRow | Store Hide Row Event. |
StoreInsertCols | Store Insert Columns Event. |
StoreInsertRows | Store Insert Rows Event. |
StoreMoveCols | Store Move Columns Event. |
StoreMoveRows | Store Move Rows Event. |
StoreReadOnly | Store ReadOnly Event. |
StoreRemoveCols | Store Remove Columns Event. |
StoreRemoveRows | Store Remove Rows Event. |
StoreRowHeight | Store Row Height Event. |
StoreStyleRowCol | Store Style Row Column Event. |
StoreZoom | Store Zoom Event. |
Undo | Undo Event. |
ValidateCell | Validate Cell Event. |
VerticalScroll | Vertical Scroll Event. |