I would like to know how the following code provided in the Excel Help Best Practice Forums , used to enable outlining on a protected sheet, can be applied to a shared workbook.
After enabling 'Share Workbook' and re-opening the file it presents the following error:Private Sub Workbook_Open()
With Sheet1
.Protect Password:="Secret", UserInterfaceOnly:=True
.EnableOutlining = True
End With
End Sub
Can it be modified to allow the outlining of protected sheets when the workbook is shared and the sheet is protected?Run-time error '1004':
Method 'Protect' of object '_Worksheet' failed
Bookmarks