DS Server

Javascript: TableRow.setMinimumHeight Method

Method|Introduced in 28.0

Description

Sets 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.

Syntax

<void> TableRow.setMinimumHeight(<number> minimumHeight, [<EmptyRequestCallback> callback], [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
minimumHeight

The row's minimum height in twips.

callback

Optional. Is called when the operation completed.

errorCallback

Optional. Is called when the operation failed with an error.

Examples

The following example demonstrates TableRow.setMinimumHeight in a practical document-editing workflow. It sets 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.

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

function configureMinimumHeight(tableRow) {
    tableRow.setMinimumHeight(
        720,
        function() {
            console.log("set minimum height completed.");
        },
        onTxError
    );
}