How do i enable "Group" & "Ungroup" in a protected sheet

How do i enable "Group" & "Ungroup" in a protected sheet

Post by RmFkaSBIYW » Thu, 25 Nov 2004 18:49:07


1 -I have grouped data in my excel sheet by using the Group rows function.
2- When i protect the sheet, the goup and Ungroup button (the + sign at the
left of the sheet), won't work.

Question:
Is there a way to proctect the sheet and keep the Group and ungroup (+
sign)function normally.

Thank you
 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by Frank Kabe » Thu, 25 Nov 2004 19:50:47

Hi
aFAIK you can't

"Fadi Haddad" <Fadi XXXX@XXXXX.COM > schrieb im

function.
at the
(+

 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by Debra Dalg » Thu, 25 Nov 2004 21:13:58

If you protect the worksheet programmatically, you can enable outlining,
and you will be able to use the groups that you have created.

The following code goes in the ThisWorkbook module:

Private Sub Workbook_Open()
With Worksheets("Sheet1")
.EnableOutlining = True
.Protect Password:="password", _
Contents:=True, UserInterfaceOnly:=True
End With
End Sub

To paste the code into the ThisWorkbook module:

Right-click on the Excel icon, to the left of the File menu
Choose View Code
Paste the code where the cursor is flashing.





--
Debra Dalgleish
Excel FAQ, Tips & Book List
http://www.yqcomputer.com/
 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by RmFka » Sat, 26 Feb 2005 23:33:03

Many Thanks Debra,

No i didn't protect the sheet programatically, i only locked the sheet by
using the protect sheet under the tools menu.


Thank you in advance for your help, and to you Frank.
 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by bWxAeHBob2 » Sun, 06 Mar 2005 02:37:05


 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by cnVkZG9qb » Sat, 03 Jun 2006 09:01:01

THANK YOU! Its a great help
 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by REJMQTEzN » Thu, 12 Mar 2009 09:15:01

I used the code you posted but i get a Run-time error 9 - subscript out of
range error.

how do i fix this?

Also, my groups are set up in sheet 6 of my workbook, does that change
anything?
 
 
 

How do i enable "Group" & "Ungroup" in a protected sheet

Post by Dave Peter » Thu, 12 Mar 2009 09:20:37

You have to change Sheet1 to the name of the sheet you're using:

With Worksheets("Sheet1")

Remember to change the password to the actual password, too.





--

Dave Peterson