TX Text Control .NET Server

Javascript: TableCellBorder.getWidth Method

Method|Introduced in 28.0

Description

Gets the cell's width in twips.

Syntax

<void> TableCellBorder.getWidth(<RequestNumberCallback> callback, [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
callback

Receives the cell's with in twips.

errorCallback

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

Examples

The following example demonstrates TableCellBorder.getWidth in a practical document-editing workflow. It gets the cell's width in twips.

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

function inspectWidth(tableCellBorder) {
    tableCellBorder.getWidth(
        function(result) {
            console.log("get width result:", result);
        },
        onTxError
    );
}