PROTECT MULTIPLE SHEETS IN EXCEL WORKBOOK SIMULTANEOUSLY?
LOOKING FOR WAY T0 PRTECT SEVERAL OR ALL SHEETS IN EXCEL WORKBOOK AT ONCE
WITHOUT HAVING TO DO EACH INDIVIDUALLY. ALSO, CONSECUTIVELY DATE SHEETS IN WORKBOOK WITHOUT HAVING TO DO INDIVIDUALLY ??? |
PROTECT MULTIPLE SHEETS IN EXCEL WORKBOOK SIMULTANEOUSLY?
You could use a macro like this:
Option Explicit Sub testme() Dim dCtr As Long Dim wks As Worksheet dCtr = DateSerial(2008, 10, 2) For Each wks In ActiveWorkbook.Worksheets wks.Name = Format(dCtr, "yyyy-mm-dd") dCtr = dCtr + 1 wks.Protect Password:="TopSecret" Next wks End Sub If you're new to macros: Debra Dalgleish has some notes how to implement macros he http://www.contextures.com/xlvba01.html David McRitchie has an intro to macros: http://www.mvps.org/dmcritchie/excel/getstarted.htm Ron de Bruin's intro to macros: http://www.rondebruin.nl/code.htm (General, Regular and Standard modules all describe the same thing.) SEAKAPTAIN wrote: LOOKING FOR WAY T0 PRTECT SEVERAL OR ALL SHEETS IN EXCEL WORKBOOK AT ONCE WITHOUT HAVING TO DO EACH INDIVIDUALLY. ALSO, CONSECUTIVELY DATE SHEETS IN WORKBOOK WITHOUT HAVING TO DO INDIVIDUALLY ??? -- Dave Peterson |
All times are GMT +1. The time now is 01:46 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com