TX Text Control .NET Server

Javascript: TextFrame.getID Method

Method|Introduced in 28.0

Description

Gets an identifier for the frame. A value of zero indicates that the image, text frame, chart, barcode or drawing has no identifier.

Syntax

<void> TextFrame.getID(<RequestNumberCallback> callback, [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
callback

Receives the current property value.

errorCallback

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

Examples

The following example demonstrates TextFrame.getID in a practical document-editing workflow. It gets an identifier for the frame. A value of zero indicates that the image, text frame, chart, barcode or drawing has no identifier.

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

function inspectID(textFrame) {
    textFrame.getID(
        function(result) {
            console.log("get id result:", result);
        },
        onTxError
    );
}