Unlock

Command line:
tlapi ‑cUNLOCK sPart
Library call:
nStatus = TLunlock (sPart)
Scripting call:
nStatus = UnlockPartition ()

Function

Remove the typesetting and edit locks from a partition. Partition edit locks and typeset locks inhibit the operation of most active API calls (for example Put Data, Compose, and Commit).

Arguments

sPart

The path of the partition to unlock. The scripting call uses the Partition property to determine the partition.

For additional command line arguments see “Common Flag Arguments”.

Scripting Call Return

The return value is zero if successful, or one of the values listed in Status Codes if not.

Note that an edit lock is also removed by Put Data if the AutoEditUnlock property is set to true.

Notes

Edit locks are usually set by Get Data or by the TopLeaf GUI when a document is edited. If you remove an edit lock, make sure that the partition is not being processed by another user.

Typesetting locks are usually set by calls to Compose or from the TopLeaf GUI.

This call removes both edit and typesetting locks.

Restrictions

There is no way to inhibit calls to Unlock.

Examples

Command line:

tlapi ‑cUNLOCK manuals/topix/volume1

Library call:

TLunlock("manuals/topix/volume1");