Hide a worksheet and require password to unhide

Anonymous
2015-01-10T21:53:40+00:00

I would like to hide several worksheets within a workbook (Excel 2010) and require a password to unhide some of them, but not all of them (so I do not want to protect the whole workbook structure).  I found the instructions below on another user forum which seemed to be exactly what I was looking for.  I followed these steps, and everything worked as described, except when I return to the VBA properties window for the worksheets where I set the Visible property to "veryhidden", I am able to change the setting to Visible or Hidden and am not prompted for the password I entered for the VBA project.  Is there another step/setting not described below that is needed to prompt for the password before the user would be able to view or change the properties for the worksheet?

  1. Go into the screen (press Alt-F11)
  2. Select the sheet you want to hide in the Project Explorer (press Ctrl-R if you don't see it)
  3. In the Properties Window (F4 if you don't see it) change the 'Visible' property to '2 - xlSheetVeryHidden'
  4. Then set a password for the VBAProject like this:
    1. 'Tools' menu up at the top
    2. Select 'VBAProject Properties...'
    3. Select 'Protection' tab
    4. Check the Checkbox for 'Lock project for viewing'
    5. Enter and Confirm your password below.
    6. Click 'OK'

This will password protect your whole Project if that works for you, but you wouldn't be able to unhide the worksheet unless you entered the Project by typeing the password.

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2015-01-11T06:47:49+00:00

All I can suggest at this point is to try doing a REPAIR install of Office/Excel because the process you have described here should result in a locked VBA project that requires you to enter the password to see the contents.

To try a Repair installation, go to the Control Panel and then to Programs and Features (in small icon layout) and find your version of Office in the list.  Highlight it and click the [Change] 'button' above the list of programs.  The install dialog window should open and I believe the SECOND entry in it is to REPAIR the installation.

Was this answer helpful?

6 people found this answer helpful.
0 comments No comments

3 additional answers

Sort by: Most helpful
  1. Anonymous
    2015-01-10T22:42:48+00:00

    Thanks for your reply...I actually did save, close and reopen but was still able to change the visibility property without entering a password

    Was this answer helpful?

    10+ people found this answer helpful.
    0 comments No comments
  2. Anonymous
    2015-01-10T22:05:44+00:00

    Hi,

    Once you've done the above bit you must save - Close and re-open the workbook for the changes to take place.

    Also note this step is very important

    4. Check the Checkbox for 'Lock project for viewing'

    Was this answer helpful?

    8 people found this answer helpful.
    0 comments No comments
  3. Anonymous
    2015-01-10T22:44:01+00:00

    ...and the "lock project for viewing" box is checked as well!

    Was this answer helpful?

    4 people found this answer helpful.
    0 comments No comments