|
|
|
Appearance | Description | Source | |
| Column Styles | Shows how to set the GridStyleInfo properties through ColStyles for all the cells of the particular column in the grid.
|  |  |
| Table Style | Shows how to set GridStyelInfo properties through the TableStyle for all the cells in the grid. |  |  |
| Row Styles | Shows how to set GridStyleInfo properties through the RowStyles for all the cells of that particular row in the grid. |  |  |
| Cell Styles | Show how to set GridStyleInfo properties through an indexer for Individual cell's in a grid. |  |  |
| Borders | Shows how to use the Borders property of the GridStyleInfo to change the style and the appearance of the Grid cells border. |  |  |
| CellTips | Shows how to set ToolTips for a range of cells or individual cells using GridStyleInfo.CellTipText property. |  |  |
| Related Events | Shows how to use events dynamically to change cell styles on a cell by cell basis. PrepareViewStyleInfo can be used to set style properties used in drawing the cell like BackColor or Border. QueryCellInfo can be used to set properties used to define the behavior of a cell like ReadOnly. |  |  |
| ExcelLikeCells | Shows how to enable Excel like selection frame and the Excel like current cell border using ExcelLikeCurrentCell and ExcelLikeSelectionFrame properties. |  |  |
| Change styles for a range of cells | Show how to use GridControl.ChangeCells method that accepts a GridRangeInfo object and a GridStyleInfo object to apply GridStyleInfo properties in the range specified. |  |  |
Formatting | Description | Source | |
| Formats for a cell, row or column | Shows how to use the GridStyleInfo's format property to set the format mask for the cellvalue. You can specify numeric format strings, date format strings or enumeration format strings as discussed in the section "Format Specifiers and Format Providers" of the .NET Framework Developers Guide. Please note that you must set the CellValueType property for the formatting to work. |  |  |
| Enable Property | Shows how to deactivate a cell and skip when moving the current cell by setting GridStyleInfo's Enabled property. |  |  |
| Related events | Shows how to use QueryCellFormattedText and SaveCellFormattedText to provide custom formatting on a cell by cell basis. QueryCellFormattedText takes the value stored in the grid, and formats it for display. SaveCellFormattedText takes a value edited in a grid cell, and removes the formatting so the raw value can be saved in the grid. |  |  |
Selections | Description | Source | |
| Programatically select a range | Shows how to programatically select a range of cells using the sample code. |  |  |
| Programatically select columns | Shows how to programatically select columns using the sample code. |  |  |
| Programatically select rows | Shows how to programatically select rows using the sample code. |  |  |
| Programatically remove selections | Shows how to programatically remove selections from the current selection ranges using the sample code. |  |  |
| Get Selected Ranges | Shows how to get the current selected ranges by looping through the rangelist to access the individual ranges.
|  |  |
| SelectionColor | Shows how to define selection color by setting the AlphaBlendSelectionColor. This property can be accessed in the designer. |  |  |
| Clear Selections | Shows how to clear selections. |  |  |
| ListBoxSelectionMode | Shows how to set ListBoxSelectionMode property. You can specify the selection behavior as One, MultiSimple, MultiExtended similar to the listbox selectionmode. |  |  |
| AllowSelection property | Shows how to set AllowSelection Property to define selection behavior of the grid. GridSelectionFlags specifies behavior for selecting cells for the grid by the user with mouse or keyboard. This property can be accessed in the VS.NET designer. |  |  |
| Related events | Shows the events raised after a selection changes. SelectionsChanging is a cancelable event. |  |  |
Drag and Drop | Description | Source | |
| Disable Drag Drop | Shows how to programmatically disable the users ability to drag cells on the grid. To turn it off ContollerOptions property has to be used. There are 2 OLE flags in that property. One controls whether the grid is a OLEDataSource and the other whether the grid is an OLEDropTarget. You can also set this property from the designer, removing these flags. |  |  |
| Related events | Shows events triggered to catch the action of moving columns and rows.The events are ColsMoving, ColsMoved, RowMoving and RowsMoved. The Moving events are cancelable, and the Moved events are notification events. The QueryOleDataSourceData event lets you customize the data that is passed through OLE D&D. |  |  |
| AllowDragSelectedCols, Rows | Shows how to enable the user to drag selected columns/rows by clicking on the column/row header. To enable set AllowDragSelectedCols/AllowDragSelectedRows to true.
|  |  |
Clipboard copy paste | Description | Source | |
| Copy | Shows how to programatically copy cells. |  |  |
| Paste | Shows how to programatically paste. |  |  |
| Cut | Shows how to programatically cut a range of cells. |  |  |
| ClipBoardFlags | Shows how the copy/paste operation can be done within the grid using the ClipBoardFlags. |  |  |
Cell Controls | Description | Source | |
| ComboBox - Setup | Shows how to assign a cell as a combobox cell. |  |  |
| ComboBox - DropDownStyle | Shows how to specify the DropDownStyle of the combobox cell. |  |  |
| CoveredCells - Setup | Shows how to specify a range of cells to be covered single cell |  |  |
| ImageCell | Shows how to specify an Image in a cell. |  |  |
Row, Column Properties | Description | Source | |
| Row, Col Count | Shows how to specify the grid's row and col count. |  |  |
| Frozen - Row, Col Count | Shows how to freeze rows, columns and to get/set the frozen columns and rows count. |  |  |
| Headers - Row, Col Count | Shows how to specify the column and row headers count. |  |  |
| RowHeights, ColumnWidths | Shows how to specify the RowHeights and ColumnWidths. |  |  |
| ResizeToFit - Rows, Columns | Shows how to optimally fit columns / rows to the contents of the cell. ResizeToFit method resizes a range of rows or column to optimally fit as per the contents in the cell. |  |  |
| Header Text - Rows, Columns | Shows how to specify the row and column header texts. |  |  |
| Move / Remove - Rows, Columns | Shows how to remove / move a range of cols and rows. |  |  |
| Hide - Rows, Columns | Shows how to hide the Rows and Columns. |  |  |
| Insert - Rows, Columns | Shows how to insert Rows and Columns. |  |  |
Alignment | Description | Source | |
| VerticalAlignment | Shows how to set Vertical Alignment in the cells of GridControl.
|  |  |
Formula Engine | Description | Source | |
| Cross Sheet references | Shows how to implement Cross sheet refrences when using multiple grids. Call static function RegisterGridAsSheet of GridFormulaEngine and pass parameters sheet name, grid model and sheet family ID. sheet family ID, an integer can be obtained by calling static method CreateSheetFamilyID of GridFormulaEngine. |  |  |
| Named Ranges | Shows how to implement Named range support. Call AddNamedRange function with an instance of GridFormulaEngine and pass two parameter name of the range and the range. |  |  |
Printing | Description | Source | |
| Printing GridControl in Landscape | Shows how to print grid in Landscape. |  |  |
Dropdowns | Description | Source | |
| Combobox cells and Doubleclicks | Shows how to handle selected index change of combo box celltype on double clicks. To enable/disable change of selected index when user double clicks on the cell, use the AllowDoubleClickChangesSelectedIndex property by accessing the GridComboBoxCellModel class.
|  |  |
GridDataBoundGrid | Description | Source | |
| Setting a DataSource | Shos the code to set the datasource |  |  |
| Removing AddNew Row | Shows how to disable the addnew row and disable edit |  |  |
| Whole Grid ReadOnly | Shows how to specify the read only property of the grid. |  |  |
| Some Cells ReadOnly | Shows how to set cell wise readonly property by handling the Model.QueryCellInfo handler. |  |  |
| Alternate Row Colors | Shows how to color alternate rows. In a GridDataBoundGrid you would have to use the PrepareViewStyleInfo event. |  |  |
| Conditionally Coloring a Cell | Shows how to conditionally color a cell by handling the PrepareViewStyleInfo handler. |  |  |
| Sorting Support | Shows how to specify the built in support for sorting in the grid. |  |  |
| Filtering a Grid | Shows how to attach a filter bar to the grid. |  |  |
Column Properties | Description | Source | |
| Setting BackColor, Font, etc. | Shows how to specify the column wise style properties. |  |  |
| Setting ColWidths | Shows how to set the column width. |  |  |
| Setting HeaderText | Shows how to specify the column header text by accessing the internal columns of the GridModelDataBinder. |  |  |
| Hiding a column | Shows how to hide columns. |  |  |
GridGroupingControl | Description | Source | |
| Setting a data source | You can set a datasource to the GroupingGrid using the following code: |  |  |
| Grouping a column from code | You can group a column using the following code: |  |  |
| UnboundColumn | Shows how to add and format unbound columns in GridGroupingControl |  |  |
| DisableResizing | Shows how to disable the resizing of rows and columns or to disable the splitter . |  |  |
| Changing the Caption Text | You can change the caption text using the following code: |  |  |
| Hiding a column | You can hide / unhide the columns using the following code: |  |  |
| Accessing the current record | You can access the current record using the following code: |  |  |
| Accessing a particular record in the GridTable | You can access a particular record in the GridTable using the following code: |  |  |
Layout and Appearances | Description | Source | |
| Freeze Columns | Shows how to freeze specified columns. |  |  |
| Preview Rows | Shows how to set texts in the preview record. This can be done handling the QueryCellStyleInfo.
|  |  |
| MultipleRowsperRecord | Shows how to create a multiple rows per record in a GridGroupingControl. This can be done by using the Columnsets property of the GridGroupingControl.
| | | |