TcxGridServerModeColumn Class
A column in a Server Mode grid Table View.
Declaration
TcxGridServerModeColumn = class(
TcxGridColumn
)
Remarks
A column displays data of the same type in a table.
Server Mode
In Unbound and Bound data access and management modes, a grid View performs all data shaping operations on a full data model stored in memory on the client machine. These modes work best on relatively small datasets (up to 20000
– 30000
records, depending on dataset structure and hardware configuration).
In Server Mode, you can use a supported grid View to work comfortably with large amounts of data stored on one of the SQL servers listed below. All Server Mode grid Views implement multiple optimizations for memory and network load management to achieve the best results in different workload profiles, available client memory, network bandwidth, etc. A Server Mode View works with a portion of data from the connected database server and loads additional records on demand.
A Server Mode grid View executes all data shaping operations on the connected database server because the full data model is not available on the client machine. All operations that require the full data model stored in client memory (such as conditional formatting) are not available in Server Mode. Refer to the Limitations section for detailed information.
Supported Servers
- Microsoft SQL Server
- Microsoft Access
- MySQL
- Firebird
- InterBase
- Oracle
- Advantage
- PostgreSQL
- SQLite
Supported Database Connectors and Data Source Components
To use one of the supported databases with a Table or Banded Table grid View in Server Mode, you need to use one of the supported database connectors and a compatible DevExpress data source component:
- FireDAC
The TFDConnection database connector is compatible with the following DevExpress data source components:
- TdxServerModeFireDACDataSource
- The FireDAC table-based server mode data source.
- TdxServerModeFireDACQueryDataSource
- The FireDAC query-based server mode data source.
- dbExpress
The TSQLConnection database connector is compatible with the following DevExpress data source components:
- TdxServerModeDBXDataSource
- The dbExpress table-based server mode data source.
- TdxServerModeDBXQueryDataSource
- The dbExpress query-based server mode data source.
- ADO
The TADOConnection database connector is compatible with the following DevExpress data source components:
- TdxServerModeADODataSource
- The ADO table-based server mode data source.
- TdxServerModeADOQueryDataSource
- The ADO query-based server mode data source.
Important
All query-based data source components do not support InterBase databases. Refer to the corresponding data source component descriptions for detailed information on requirements and limitations.
In-Place Editors
A column can use any unbound editor shipped with the ExpressEditors Library as an in-place editor for cell edit operations. An in-place editor instance exists (and, therefore, consumes memory and other system resources, such as a WinAPI handle) only when a column cell is being edited. Otherwise, the column displays a static editor image for resource usage optimization.
To switch between available editors, you can use the PropertiesClassName or PropertiesClass property. Use the Properties property to configure the in-place editor associated with the column.
Default In-Place Editor and Data Types
When PropertiesClassName and PropertiesClass properties are unspecified, the data type of the underlying dataset field determines the active in-place editor according to the following table:
Dataset Field Type | Default In-Place Editor | Description |
---|---|---|
ftBoolean |
TcxCheckBox | A check box editor with support for three states. |
ftCurrency , ftBCD , and ftFMTBcd |
TcxCurrencyEdit | A numeric editor for currency values. |
ftDate and ftDateTime |
TcxDateEdit | A date editor with a drop-down calendar. |
ftTime |
TcxTimeEdit | A spin editor for time values. |
ftBytes , ftVarBytes , ftBlob , ftFmtMemo , ftParadoxOle , ftDBaseOle , and ftTypedBinary |
TcxBlobEdit | A Binary Large Object (BLOB) editor. |
ftMemo |
TcxMemo | A multi-line editor for plain text. |
ftGraphic |
TcxImage | An editor designed to display images. |
All other types | TcxMaskEdit | A single-line text editor with support for input masks. |
Main API Members
The list below outlines key members of the TcxGridServerModeColumn
class. These members allow you to configure columns in Server Mode Table grid Views.
General Appearance Settings
- ApplyBestFit | BestFitMaxWidth
- Allow you to adjust the column width to display content in full and limit the maximum column width in this mode.
- Caption | AlternateCaption
- Specify main and alternative captions for the column. An alternative column caption can replace the main caption in customization dialogs, filter panels, etc.
- HeaderGlyph | HeaderImageIndex
- Allow you to assign a glyph to the column header.
- OnCustomDrawCell
- Allows you to override or complement column draw routines.
- OnGetDisplayText | OnGetFilterDisplayText
- Allow you to customize display text and column captions displayed in a filter drop-down window.
- OnGetFilterImages | OnGetFilterValues
- Allow you to customize the column’s filter drop-down window.
- Styles
- Allows you to customize the appearance of different column elements.
Column Layout Settings
- FooterAlignmentHorz
- Allows you to position column footer cells.
- HeaderAlignmentHorz | HeaderAlignmentVert
- Position the column header horizontally and vertically.
- HeaderGlyphAlignmentHorz | HeaderGlyphAlignmentVert
- Specify the glyph position within the column header.
- LayoutItem | RowLayoutItem
- Allow you to configure the column in a custom row layout.
- MinWidth
- Specifies the minimum column width, in pixels.
In-Place Editor Settings
- Editing
- Specifies if the assigned in-place cell editor is active.
- OnGetProperties
- Allows you to display different in-place editors for different records or customize editor settings based on custom conditions.
- OnGetPropertiesForEdit
- Allows you to change the assigned in-place editor and customize its settings when a user invokes the editor.
- Properties
- Provides access to the settings of the assigned in-place editor.
- PropertiesClass
- Specifies the active in-place editor class. At design time, you can use the Properties node in the Object Inspector to assign an in-place editor to the column and configure the editor.
- RepositoryItem
Allows you to associate the column with a repository item that defines the required in-place editor and its settings.
Tip
Repository items are particularly useful if you need to share in-place editor settings between multiple grid View items or customize editor settings in OnGetProperties and OnGetPropertiesForEdit event handlers.
Data Management
- DataBinding
- Provides access to data binding settings.
- GroupIndex
- Allows you to group columns in the parent grid View by the current column.
- SortIndex | SortOrder
- Allow you to sort data in the parent grid View against the current column.
Grid View-Related API Members
- IsBottom | IsLeft | IsMostBottom | IsMostLeft | IsMostRight | IsRight | IsTop
- Allow you to identify the column’s position within the parent grid View.
- FixedKind
- Allows you to fix the column or dock it to the left when users scroll the parent grid View to the right.
- Focused
- Specifies if the column has focus.
- Index
- Defines the column position in its parent grid View.
- IsFirst | IsLast
- Identify if the column is the first or last in the parent grid View’s collection of visible columns.
- IsPreview
- Allows you to identify if the column has a preview section.
- MakeVisible
- Scrolls the parent grid View to display the current column.
- Selected
- Identifies if the column is selected.
- Summary
- Provides access to column summary settings.
- VisibleForEditForm | VisibleForRowLayout
- Specify if the column is visible in an in-place Edit Form and the custom row layout.
General-Purpose API Members
- Editable
- Allows you to identify if the column is editable.
- GridView
- Provides access to the parent grid View.
- Options
- Allows you to configure general column settings.
- RestoreDefaults
- Restores the default values of column type-specific settings, such as Caption and Width.
- Visible
- Specifies if the column is visible.
Grid Column Deletion
To delete a grid column, release it directly in code (call the Free procedure in Delphi or use the delete
keyword in C++Builder):
Direct TcxGridServerModeColumn Class References
The following public API members reference a TcxGridServerModeColumn
object:
- TcxGridServerModeTableView.CreateColumn
- Creates a new column and adds it to the Columns collection.
- TcxGridServerModeTableView.Columns
- Provides zero-based indexed access to the View’s columns.
Other Grid Column Classes
Unbound
- TcxGridBandedColumn
- A column in an unbound Banded Table View.
- TcxGridColumn
- A column in an unbound grid Table View.
Data-Aware
- TcxGridDBColumn
- A column in a data-aware grid Table View.
- TcxGridDBBandedColumn
- A column in a data-aware Banded Table grid View.
Server Mode
- TcxGridServerModeBandedColumn
- A column of a Banded Table View in Server Mode.
Related Compiled Demo
To see Server Mode Table and Banded Table Views in action, run the Grid and Data Editors demo in the VCL Demo Center installed with compiled DevExpress demos. Click the Server Mode (Table) or Server Mode (Query) item in the side bar to the left. The selected demo prompts you to connect to an existing SQL server with specified credentials.
Tip
You can find full source code for installed compiled [Data Grid] demos in the following folder:
%PUBLIC%\Public Documents\DevExpress VCL Demos\MegaDemos\Product Demos\ExpressQuantumGrid
Limitations
Server Mode columns do not support all functionality that requires the full data model stored in memory:
- Master-detail relationships
- Custom sort, filter, and group operations
- Calculated fields and unbound columns
- Conditional formatting
- Custom summaries
- Web-style row selection