Consulting

Results 1 to 6 of 6

Thread: How to protect a workbook?

  1. #1
    VBAX Regular
    Joined
    Dec 2007
    Posts
    23
    Location

    How to protect a workbook?

    Does anyone know of a macro that will protect an entire workbook (and disable locked cells) with a password? I need to protect a workbook with about 75 worksheets and don't want to have to protect each one individually, but I have cells that can not be altered in each worksheet.

  2. #2
    Moderator VBAX Wizard Aussiebear's Avatar
    Joined
    Dec 2005
    Location
    Queensland
    Posts
    5,060
    Location
    G'day cmm0812, Have a look at the following website;

    http://j-walk.com/ss/Excel/faqs/protectionFAQ.htm
    Remember To Do the Following....
    Use [Code].... [/Code] tags when posting code to the thread.
    Mark your thread as Solved if satisfied by using the Thread Tools options.
    If posting the same issue to another forum please show the link

  3. #3
    VBAX Regular
    Joined
    Dec 2007
    Posts
    23
    Location
    Thanks. What I am looking for is to protect the structure of the workbook (as done when protecting sheets), so that users cannot select locked cells but can unhide columns with one password that will unlock the entire file. It seems very tedious to have to password-protect each sheet in my file so that locked cells are protected and have to unlock each sheet when I need users to unhide a row.

    Thanks

  4. #4
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    use the same password on all worksheets and protecte/unprotect them all at one time? Does that sound like it might work?
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

  5. #5
    VBAX Regular
    Joined
    Dec 2007
    Posts
    23
    Location
    That does not work. They all have to be protected individually.

  6. #6
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    Quote Originally Posted by cmm0812
    Thanks. What I am looking for is to protect the structure of the workbook (as done when protecting sheets), so that users cannot select locked cells but can unhide columns with one password that will unlock the entire file. It seems very tedious to have to password-protect each sheet in my file so that locked cells are protected and have to unlock each sheet when I need users to unhide a row.

    Thanks
    You should be able to unhide a row on a sheet by unprotecting it, unhide the row...then protect it again all by using a macro.....you need to give a little more info. Are each of these sheets protected with a different password according to user?
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

Posting Permissions

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