Adding a date range Lock
This article explains how to add a date range Lock to a Form or Subform to prevent users from adding or editing Records that belong to a particular time period. It presents the prerequisites for your Form or Subform and it showcases how date range Locks work in the Data Entry page.
By adding a date range Lock you can preserve versions of the Records after they have been validated by your information management processes for example and make sure that no user can edit them.
A date range Lock can be set on any Form or Subform that has a Date/Month/Week field added as a Key field or on any Database or Folder containing a Form with such a Key field. Users will get an error message when they try to add a Record for the locked period and they won't be able to save the Record.
So to add a date range Lock to a Folder, Form or a Subform, you need to add a Date/Month/Week field to your Form or Subform and make it a Key field in order to add the Lock.
Alternatively, you can add a rule based Lock.
How to add a date range Lock
- Before adding a date range Lock to your Form make sure that it contains a Date/Month/Week which is a Key field.
- On the Database List page, click on the Database that contains the Form you want to add a Lock to.
- Click on "Database settings" to open the Database Settings page.
- Navigate to the resource to which you want to add the date range Lock. Click on the arrows to reveal the contents of Folders, if needed.
- In the Resource side panel of the Database Design section, click on "Locks" to open the Locks tab.
- Click on "Add date range lock".
- Give a name to the Lock.
- Select the starting date and the ending date for your Lock. Click on the Calendar icon to reveal a Calendar or type the date following the format "YYYY-MM-DD".
- When checking the box 'Active' the Lock remains active. If you uncheck it you can suspend the Lock temporarily. You will still be able to view it in the side panel.
- Click on "Save" to save the Lock.
- When users try to add a Record for that period or edit a Record for that period they will get a warning and won't be able to save the Record.