Is there a way to relock a worksheet?
How can I set excel to always require a password to make modifications on a sheet? So, if someone closes the program and forgets to protect the workbook, Excel will automatically do it with the same password?
Relocking a worksheet
-
-
-
Re: Relocking a worksheet
You could add code in the workbooks BeforeClose event to set the password/protection.
The best way to get the code for that would be to turn on the macro recorder and do the password/protection manually.
-
-
Re: Relocking a worksheet
Just goto Tools>Macro...Record New Macro...
Then carry out the protection manually, then stop the recorder.
To access the generated code press ALT+F11.
There should be a module there containing the code.
-
Re: Relocking a worksheet
Or how bout this? Is there a way to allow users to edit cells but not save the file? therefore the file is always locked and will never be changed unless a password is provided?
Participate now!
Don’t have an account yet? Register yourself now and be a part of our community!