Skip to Content
0
Former Member
May 20, 2016 at 02:38 PM

Group/Ungroup not working in a protected sheet

25 Views

Hi Experts,

I want to enable group/un group in a protected sheet, I tried below VBA code, however it won't work when i refresh the template.

Private Sub Workbook_Open()

With Worksheets("Emp Summary")

.EnableOutlining = True

.Protect UserInterfaceOnly:=True

End With

End Sub

Can anyone help me on this.

Thanks in advance.

Regards,

Srikant