protect worksheet before closing

P

PegL

You can use the Workbook_BeforeClose event procedure in
VBA. You can check whether the worksheet is protected and
protect it if it is.
-----Original Message-----
Hello,

I have a worksheet that is protected leaving a few cells
unprotected for inputing data. If the user want to
modify the worksheet and leave it unprotected after the
changes is made, how can I set the worksheet to check the
protection and protect it automatically when the user
close the workbook?
 
Top