TX Text Control .NET Server

Javascript: DateFormField.getDate Method

Method|Introduced in 28.0

Description

Gets the DateFormField's date.

Syntax

<void> DateFormField.getDate(<RequestNumberCallback> callback, [<ErrorCallback> errorCallback])

Parameters

ParameterDescription
callback

Receives the date in Unix Time.

errorCallback

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

Examples

The following example demonstrates DateFormField.getDate in a practical document-editing workflow. It gets the DateFormField's date.

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

function inspectDate(dateFormField) {
    dateFormField.getDate(
        function(result) {
            console.log("get date result:", result);
        },
        onTxError
    );
}