Have you tried using that exact expression in the "lock expression" in the user's privilege set for this table?
I don't know if it will work, but it seems quite possible.
Another option: Add a "new record" popover button to your layout. The user clicks the Popover to open a panel with one global field for each regular field where they may need to enter data on the new record. Clicking a Save button inside this panel runs a script that a) creates a new record b) uses a series of set field steps to transfer the data to the corresponding fields in the new records and c) closes the popover and clears the global fields. You can also include code that checks the validity of the user's inputted data as well if that is necessary.
Thanks again for your time.
I did try the "lock expression", but I didn't get it working properly.
Your suggestion to use a popover button sounds like a great idea. The problem I am dealing with, is that the users for this application are teachers. And they are doing the most terrible things when they are behind a computer. They click on everything they see, even when they are in "adding" mode.
And yes, I can write code to prevent all these things, but that is quiet a lot of work. Using a popover seems like a much better and safer idea. The validity can be built in the pop over, and that is less work then adding all kind of extra security while adding a record in the regular way.
Thanks again Phil.