DS Server

Javascript: TableCellBorder.setColor Method

Method|Introduced in 28.0

Description

Sets the cell's border color.

Syntax

<void> TableCellBorder.setColor(<string> color, [<EmptyRequestCallback> callback], [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
color

The cell's border color.

callback

Optional. Is called when the operation completed.

errorCallback

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

Examples

The following example demonstrates TableCellBorder.setColor in a practical document-editing workflow. It sets the cell's border color.

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

function configureColor(tableCellBorder) {
    tableCellBorder.setColor(
        "#ffd54f",
        function() {
            console.log("set color completed.");
        },
        onTxError
    );
}