Excel 2007: Tried Grouping/Protect VBA and did not work - Need to have both

Michelle Deigh

New Member
Joined
Jan 24, 2013
Messages
17
I have been trying the many different solutions over the various forums regarding protecting the cells/workbook but retaining the ability to utilize grouping. This is not a worksheet that I will be able to activate or frequently open & close as it is due to go up on Sharepoint and will be owned by someone else. It has data that is pasted in one sheet and activates formulas on the 10 other tabs as to resources, time worked and percent on various projects which then rolls up into groups and totals.

The grouping is so that the various management levels can see the sheet according to what data level they require. But protection is preferred so as to avoid accidental deletions etc.

I keep testing the codes and it never allows the grouping but locks the entire thing down! There is only one piece of code:

Private Sub Workbook_Open()
Dim ws As Worksheet
Const C_PWD = "adminaig"
For Each ws In ThisWorkbook.Worksheets
With ws
.Protect C_PWD, DrawingObjects:=False, UserInterfaceOnly:=True
.EnableOutlining = True
End With
Next ws
End Sub

-that worked a few times and then went to total protection.

Please help me!
Thanks in Advance!

Michelle
 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.
While I never found a way to do this, I managed to find a way around it. As I am told to create something and never am fully told the why, I did not know it could be read only. Still I will keep wondering on this as it is bound to come up again!
 
Upvote 0

Forum statistics

Threads
1,217,300
Messages
6,135,716
Members
449,959
Latest member
choy96

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top