Results 1 to 2 of 2
  1. #1
    4 Star Lounger
    Join Date
    Dec 2003
    Location
    Perth, Western Australia, Australia
    Posts
    487
    Thanks
    75
    Thanked 2 Times in 1 Post

    Allow Group and outline on protect sheet

    Loungers, I need to be able to allow a user to group and ungroup rows on a protected sheet.

    I assume that some sort of code is required or if there are any other solutions

    If anyone has any suggestions/expample of code to do this, it woudl be much appreciated.

    (I thought I posted this yesterday - but cant seem to find the post in the lounge)

  2. #2
    WS Lounge VIP sdckapr's Avatar
    Join Date
    Jul 2002
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    11,225
    Thanks
    14
    Thanked 342 Times in 335 Posts
    Add this to the ThisWorkbook Object in VBA:
    Code:
    Option Explicit
    Private Sub Workbook_Open()
      With Worksheets("MySheet")
        .Protect Password:="MyPassword", UserInterfaceOnly:=True
        .EnableOutlining = True
      End With
    End Sub
    Change the worksheet name and password as appropriate. The parameters are reset after the workbook is closed so it must be done when the workbook is opened.
    Steve

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •