Skip to main content
This object represents a single table cell of a table block. This is an element of a TableCells collection. The object provides access to the name of the cell, its coordinates in pixels, and contents of the cell. Each table cell is represented as a separate block. To access contents of the cell you should use the Block property. The type of the contents (e.g., text, picture) depends on the IBlock::Type property. If the table cell contains text, you can access the text of the table cell and other text properties using the IBlock::GetAsTextBlock method. A cell has four coordinates — the coordinates of the left, right, top and bottom separators that enclose it. Cell coordinates are the coordinates in pixels. Table cell coordinates cannot be changed directly. They are affected by ITableCells::Merge and ITableCells::Split methods. But be aware that these operations not only change attributes of a single cell, but affect the cells collection as a whole, adding or removing cells.

Properties

NameTypeDescription
ApplicationEngine, read-onlyReturns the Engine object.
BlockBlock, read-onlyProvides access to the block of the cell.
Bottomint, read-onlyStores coordinate of the bottom border of the cell in pixels.
Leftint, read-onlyStores coordinate of the left border of the cell in a pixels.
Rightint, read-onlyStores coordinate of the right border of the cell in pixels.
Topint, read-onlyStores coordinate of the top border of the cell in pixels.

Methods

NameDescription
ChangeBlockTypeChanges the type of the block which corresponds to the table cell.
TableCell Object Diagram

Output parameter

This object is the output parameter of the Item method of the TableCells object.

Samples

FREngine.IBlock block;
// Retrieving table cells
if (block.Type == FREngine.BlockTypeEnum.BT_Table)
{
 FREngine.ITableBlock tableBlock = block.GetAsTableBlock();
 for( int iCell = 0; iCell < tableBlock.Cells.Count; iCell++ ) {
  FREngine.ITableCell cell = tableBlock.Cells[iCell];
  // do something with the cell
 }
}
The object is used in the following code samples:

See also

TableBlock TableCells Working with Layout and Blocks Working with Text Working with Properties