TX Text Control .NET Server

Javascript: TextField.getDoubledInputPosition Method

Method|Introduced in 28.0

Description

Sets whether a text field has a doubled input position in front of its first character and behind its last character.

Syntax

<void> TextField.getDoubledInputPosition(<RequestBooleanCallback> callback, [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
callback

Receives whether a text field has a doubled input position in front of its first character and behind its last character.

errorCallback

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

Examples

The following example demonstrates TextField.getDoubledInputPosition in a practical document-editing workflow. It sets whether a text field has a doubled input position in front of its first character and behind its last character.

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

function inspectDoubledInputPosition(textField) {
    textField.getDoubledInputPosition(
        function(result) {
            if (result) {
                console.log("get doubled input position is available.");
            } else {
                console.warn("get doubled input position is not available in the current document state.");
            }
        },
        onTxError
    );
}