DS Server

TableRow Object

Object|Introduced in 28.0

Description

Represents a single row of a table in a Text Control document.

Syntax

TableRow

Examples

The following example demonstrates TableRow in a practical document-editing workflow. It represents a single row of a table in a Text Control document.

function onTxError(error) {
    console.error("TX Text Control error:", error.msg);
    error.handled = true;
}

function inspectTableRow(tableRow) {
    tableRow.getAllowPageBreak(
        function(result) {
            if (result) {
                console.log("get allow page break is available.");
            } else {
                console.warn("get allow page break is not available in the current document state.");
            }
        },
        onTxError
    );
}

Members

Methods

MethodDescription
getAllowPageBreakGets a value specifying how the table row is formatted at page breaks.
getCellFormatGets the formatting attributes of a table row.
getIsHeaderGets a value specifying whether the table row is part of the table's header.
getMinimumHeightGets the minimum height, in twips, of the table row. The table row is formatted with this height if the text is smaller. Otherwise the row grows as necessary. If the property value is zero, the table row's height is always determined through the containing text.
getRowGets the number of the table row represented through this table row object.
selectSelects the table row.
setAllowPageBreakSets a value specifying how the table row is formatted at page breaks. The property value is True, if the table row can be formatted across page breaks. The property value is False, if the table row must not be formatted across page breaks.
setIsHeaderSets a value specifying whether the table row is part of the table's header.
setMinimumHeightSets the minimum height, in twips, of the table row. The table row is formatted with this height if the text is smaller. Otherwise the row grows as necessary. If the property value is zero, the table row's height is always determined through the containing text.