Skip to main content

TcxCustomGrid Class

The base class for the Data Grid control.

Declaration

TcxCustomGrid = class(
    TcxControl,
    IcxNavigator,
    IcxNavigatorRecordPosition,
    IdxSkinSupport,
    IcxLockedStatePaint,
    IcxLockedStateFontChanged
)

Remarks

The Data Grid allows you to display data as a table and in a variety of other formats. The control has multiple built-in features that allow users to shape and edit data.

VCL Data Grid: A Grid Table View Example

Main API Members

The list below outlines key members of the TcxCustomGrid class. These members allow you to configure general Data Grid control settings and manage grid Views/levels.

Appearance Settings

Images
Specifies the image source for grid level tabs and column headers.
LevelTabs
Provides access to grid level tab appearance settings.
LockedStateImageOptions
Provides access to Locked View image settings.
LookAndFeel
Provides access to look & feel settings at the Data Grid control level.
OnPrepareLockedStateImage
Allows you to custom draw a Locked View image.
RootLevelOptions | RootLevelStyles
Allow you to customize grid level appearance at the root hierarchy level.

Grid Level Management

ActiveLevel
Specifies the active root grid level.
Levels
Provides access to the root grid level collection.

Grid View Management

ActiveView
Provides access to the grid View associated with the active root level.
CreateView
Creates a new grid View of any supported type.
ViewCount
Returns the number of grid Views accessible through the Views property.
Views
Provides indexed access to all created grid Views.

User Interaction APIs

Automation
Provides access to UI Automation and accessibility-related settings.[1]
FocusedView
Allows you to move focus between grid Views.
OnActiveTabChanged | OnActiveTabChangedEx | OnFocusedViewChanged
Allow you to respond to user navigation between grid Views.
TabStop
Specifies if users can press Tab to focus the Data Grid control.

General-Purpose API Members

BeginUpdate | EndUpdate | CancelUpdate
Allow you to avoid excessive redraw operations during batch data and appearance changes.
Invalidate | LayoutChanged | SizeChanged
Redraw the Data Grid control on demand.
OnLayoutChanged
Allows you to execute custom code in response to grid layout changes.

Terminal TcxCustomGrid Class Descendant

Do not use the TcxCustomGrid class directly. Use the TcxGrid control instead.

Get Started

The following tutorials help you get acquainted with the Data Grid control and its Views:

Table View
This tutorial describes how to add a Data Grid control to your application and set up a Table View display style.
Banded Table View
This tutorial describes how to add a Data Grid control, specify data connections, and adjust appearance settings in a Banded Table View.
Footnotes
  1. Each grid Table View and column has its own Automation property (TcxGridTableView.Automation and TcxCustomGridTableItem.Automation).

See Also