I have a macro that runs a loop on most sheets to clear colored cells. All worksheets are protected and I can't seem to integrate my protect and unprotect macros (which work!) into the clearing macro. Here are all 3:
Clear cells
![]()
Please Login or Register to view this content.
Unprotect all sheets
![]()
Please Login or Register to view this content.
Protect all sheets
![]()
Please Login or Register to view this content.
How can I integrate the 1. unprotect all sheets, 2. run clear macro, and 3. protect all sheets?
Note that "UserInterfaceOnly:=True" does not consistently work. It fails when the workbook is opened having been previously protected..
Bookmarks