![]() |
Protection of worksheets
Can worksheets be protected by one password rather than passwords for each
worksheet? I am using certain ranges allowed to be edited/used by the user but not all worksheets are the same usable ranges. Possible based on my current settings for the worksheets, can be protected by one password and yet the data will continue to update itself? Tired of entering the password for all sheets to change things! |
Protection of worksheets
Hi,
Here are 2 custom routines which will help you protect and unprotect all the worksheets in the currently open workbook in one go. Sub MyProtect() Dim sht As Worksheet For Each sht In ActiveWorkbook.Sheets sht.Protect "abcd" Next End Sub Sub MyUnprotect() Dim sht As Worksheet For Each sht In ActiveWorkbook.Sheets sht.Unprotect "abcd" Next End Sub Copy these in the VBA/Maro Editing window to your workbook and run. Please note 'abcd' is the password, which you can replace as per your choice. HTH, -- Pranav Vaidya VBA Developer PN, MH-India If you think my answer is useful, please rate this post as an ANSWER!! "Asiageek" wrote: Can worksheets be protected by one password rather than passwords for each worksheet? I am using certain ranges allowed to be edited/used by the user but not all worksheets are the same usable ranges. Possible based on my current settings for the worksheets, can be protected by one password and yet the data will continue to update itself? Tired of entering the password for all sheets to change things! |
All times are GMT +1. The time now is 02:10 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com