TX Text Control .NET Server

Javascript: TXTextControl.EditMode Enumeration

Enumeration

Description

Determines the possible document edit modes.

Members

MemberDescription
EditThe document's text can be edited.
ReadAndSelectThe document's text is read only but can be selected.
ReadOnlyThe document's text is read only.
UsePasswordA dialog box to enter a password is opened to protect the edit mode. This value can only be combined with EditMode.ReadAndSelect using the bitwise or operator.

Examples

The following example uses TXTextControl.EditMode.Edit (the document's text can be edited.) in a document-editing workflow.

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

TXTextControl.setEditMode(
    TXTextControl.EditMode.Edit,
    function() {
        console.log("set edit mode completed.");
    },
    onTxError
);