Working With Borland TDBGrid

Applies to TestComplete 15.10, last modified on December 15, 2021

TestComplete includes the VCL Control Support plugin that expands TestComplete abilities to interact with VCL TDBGrid controls from scripts. If this plugin is installed and enabled, TestComplete extends the TDBGrid control functionality with methods, properties and actions of the BorlandTDBGrid object. These supplementary members let you perform specific operations over the TDBGrid control, for example, simulate clicks on grid cells, obtains and set values in grid cells, expand and collapse rows and so on.

Since the TDBGrid is a VCL control and can be used within VCL (Delphi or C++Builder) applications, which are always “open” to TestComplete, the internal methods and properties of the TDBGrid control are also visible to TestComplete. This “openness” means that you can use the TDBGrid’s “native” methods and properties to perform the needed actions as well.

Finally, you can work with the TDBGrid controls as a black-box application windows, that is, you can simulate various mouse actions and keystrokes, record and play back low-level procedures, and so on. For more information, see Simulating User Actions.

The topics of this section provide detailed information and sample code for performing various operations with the TDBGrid control.

In This Section

Searching for Records in Borland TDBGrid

Describes how to search for a specific record within the TDBGrid control.

Selecting Cells in Borland TDBGrid

Describes the approaches used to select individual grid cells.

Activating In-place Editors in Borland TDBGrid

Explains how you can activate the cell’s in-place editor.

Obtaining and Setting Cell Values in Borland TDBGrid

Describes how you can get and set values in individual grid cells.

Copying and Pasting Cell Values in Borland TDBGrid

Describes how you can copy or paste the cell value.

Simulating Mouse Clicks Over Column Headers in Borland TDBGrid

Explains how to simulate a mouse click over the column header.

Selecting Multiple Rows in Borland TDBGrid

Describes how you can select several rows within the TDBGrid control.

Obtaining Selected Rows in Borland TDBGrid

Explains how to obtain the row(s) selected in the TDBGrid control.

Iterating Through Rows in Borland TDBGrid

Gives an example of processing the grid rows data in a loop and saing the grid contents to an .XML file.

Checking TDBGrid Options From Scripts

Describes how to create a script routine that determines which values are specified in the TDBGrid.Options property.

Related Topics of Interest

Table Checkpoints

Explains how to create checkpoints that verify data displayed in tabular controls.

See Also

Borland TDBGrid Support
Working With Grids
Supported VCL and CLX Controls
About Open Applications

Highlight search results