You can implement the “Locked” yes/no field in the data type. So, when a user visits the edit screen (page or group), you can set the field to yes. You can check this value before displaying the screen. When a user presses “Save” or “Cancel” on the edit screen, you can change the field back to no. The trouble is if the user leaves the screen in some other, uncontrolled way … Maybe someone else has a solution for that.
Another, more systematic way to tackle record locking was discussed here: