DS Server

Javascript: Line.getNumber Method

Method|Introduced in 28.0

Description

Gets the line's number.

Syntax

<void> Line.getNumber(<RequestNumberCallback> callback, [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
callback

Receives the line's number.

errorCallback

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

Examples

The following example demonstrates Line.getNumber in a practical document-editing workflow. It gets the line's number.

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

function inspectNumber(line) {
    line.getNumber(
        function(result) {
            console.log("get number result:", result);
        },
        onTxError
    );
}