In the definition of the Privilege set for the users, set all fields in that table to be editable only if your locking field EditRecordYesNo = "Yes". I would suggest you don't set that privilege feature for that field itself, though, or else they will not be able to turn it on and off.
You can set the field definition of that field to auto-insert 'No' at record creation.
I would suggest you don't set that privilege feature for that field itself, though, or else they will not be able to turn it on and off.
Unless you put the field that "locks" the record in a different, related table, users who have this privilege set won't be able to modify the value in the field to unlock it, OR you use a script to modify this field that has the "run with full access privileges" option set.
See "Editing record access privileges" in FileMaker Help and check out this particular sub section: "Entering a formula for limiting access on a record-by-record basis" for a detailed description of how to set up record level access control.
Phil is perfectly correct, of course - I was thinking that the 'Limited...' field access privileges had the same settings available as the record limiting.