Use the Current event of the form to call:
Call LockBoundControls(Me, Nz(Me.[YourYesNoField],False))
You probably want to do this in Form_AfterUpdate as well.
--
Allen Browne - Microsoft MVP. Perth, Western Australia
Reply to group, rather than allenbrowne at mvps dot org.
Priscilla said:
I implemented the code you had listed on your site. (Works like a
charm-thanks. However in my case I would like to only lock down certain
records that have an attribute. For example, I have 700 records that
contain
various fields. One of these fields is of type yes/no. I would only like
to
lock the form for records that have the "yes" selected, versus locking all
forms. Can the method you displayed here be used to accomplish this?