version 6.5
WR LOCK DOCUMENT (area; status)
Parameter | Type | Description | |
area | Longint | 4D Write area | |
status | Integer | 0=unlocked | |
1=locked |
Description
The WR LOCK DOCUMENT prevents users from modifying the 4D Write area referenced by area. Once the document is locked, users cannot paste text, cut text, enter or modify text. Scrolling, copying, searching and printing the document are still possible.
To determine the lock status of the current document, you can use the WR GET DOCUMENT INFO command. This information is also displayed in the Document information dialog. You can access that dialog by selecting Document information from the Tools menu.
If status equals 1, the document will be locked
If status equals 0, the document will be unlocked
Example
You want to close records definitively and prevent users from editing them.
`It will not be possible to edit the document WR LOCK DOCUMENT(Area;1) `Users will not be able to select the menu command Tools>Document Information `to open the dialog box and enable the option WR LOCK COMMAND(Area;wr cmd doc information;0)
See also