Results 1 to 3 of 3
  1. #1
    5 Star Lounger
    Join Date
    Jan 2004
    Location
    Praha
    Posts
    988
    Thanks
    56
    Thanked 105 Times in 90 Posts
    Is it possible to protect a Worksheet in such a way that cells cannot have their contents changed but grouped rows can be expanded or collapsed ?

    I've tried every option in the "Protection" menu item, but with no success.

    PS I've succeed in assigning a macro which does all this to a tiny text box over the +/- grouping symbol but that is so clunky and inflexible as to defy description !!

    Thanks

  2. #2
    WS Lounge VIP rory's Avatar
    Join Date
    Dec 2000
    Location
    Burwash, East Sussex, United Kingdom
    Posts
    6,280
    Thanks
    3
    Thanked 191 Times in 177 Posts
    Yes, but you have to protect the sheet in code, specifying the UserInterfaceOnly:=True argument and setting the sheet's EnableOutlining property to True:
    Code:
    ActiveSheet.EnableOutlining = True
    ActiveSheet.Protect contents:=True, userInterfaceOnly:=True
    Note that you have to reset this everytime the workbook is opened.
    Regards,
    Rory

    Microsoft MVP - Excel

  3. #3
    5 Star Lounger
    Join Date
    Jan 2004
    Location
    Praha
    Posts
    988
    Thanks
    56
    Thanked 105 Times in 90 Posts
    Perfect - thank you so much !

Posting Permissions

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