+ Reply to Thread
Results 1 to 8 of 8

User Passwords to view specific sheets

  1. #1
    Registered User
    Join Date
    08-01-2011
    Location
    London, England
    MS-Off Ver
    Office 365 updated
    Posts
    13

    User Passwords to view specific sheets

    Hi

    I have a workbook with 9 worksheets in it. When the workbook is opened by a user, I need them to have to fill in a password immediately be able to view specific sheets. I have 4 types of User.

    1. There are Sales Representatives (Team 1) which need to be able to view sheets 1, 2 and 5.
    2. There are Sales Representatives (Team 2) which need to be able to view sheets 3, 6 and 7.
    3. There are Managers which need to be able to view sheets 8 and 9.
    4. There is a Sales Director who needs to be able to view all the sheets.

    I have found a few answers on the forum which get me half way there but my VBA is not great!

    Please can anyone help with a solution?

    Many thanks for any help

    Best Wishes

    Kev

  2. #2
    Registered User
    Join Date
    08-01-2011
    Location
    London, England
    MS-Off Ver
    Office 365 updated
    Posts
    13

    Re: User Passwords to view specific sheets

    Below is a link which gets half way there!

    http://www.mrexcel.com/forum/excel-q...ksheets-3.html

    Many thanks for any help to get the full solution

  3. #3
    Forum Expert skywriter's Avatar
    Join Date
    06-09-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    2,760

    Re: User Passwords to view specific sheets

    This is not something I'm an expert at, but here's a start. We could discuss how to further customize it for your needs if you are interested.
    The password is "Password", enter and you will see what happens, close it and when you open it again leave it blank, this would be an example if we used another password. It seems you have to have at least one sheet visible, so I have the sheet you see that is named MainWorksheet as you see after the password process this sheet disappears, so for your needs we could do the same, just have a blank sheet that is the only visible sheet while someone enters their password and then the sheets they should have access to become visible and the token sheet goes away.

    Let me know.
    Attached Files Attached Files
    Click the * Add Reputation button in the lower left hand corner of this post to say thanks.

    Don't forget to mark this thread SOLVED by going to the "Thread Tools" drop down list above your first post and choosing solved.

  4. #4
    Registered User
    Join Date
    08-01-2011
    Location
    London, England
    MS-Off Ver
    Office 365 updated
    Posts
    13

    Re: User Passwords to view specific sheets

    Many thanks Skywriter.

    This works well for one user - the big challenge I am having is how to set up different views for different users after they have entered their password.

  5. #5
    Forum Expert skywriter's Avatar
    Join Date
    06-09-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    2,760

    Re: User Passwords to view specific sheets

    Quote Originally Posted by kevdas View Post
    Many thanks Skywriter.

    This works well for one user - the big challenge I am having is how to set up different views for different users after they have entered their password.
    It's customizable, I have ideas on how to do it. You just have to decide if you want to move forward with some help.
    The idea is we have a hidden sheet for passwords. We could have either one password for each group or each person could have their own password. What we do is one column is the passwords and the column next to it lists their access group. My code would first make sure if their password is valid, if so what access rights do they have and then it would display the appropriate sheets. You would lock and control the VBA project so the password sheet only gets unhidden and edited by you.
    If you click on a sheet name in the project explorer and then choose view properties, then you just change the visible property so you can work on the sheet and then change it back to very hidden and it's inaccessible to any users.

  6. #6
    Valued Forum Contributor john55's Avatar
    Join Date
    10-23-2010
    Location
    Europe
    MS-Off Ver
    Excel for Microsoft 365
    Posts
    2,028

    Re: User Passwords to view specific sheets

    Hi,
    as an option you can see this file, the author is Roy UK http://www.excel-it.com/!
    Attached Files Attached Files
    Last edited by john55; 04-23-2015 at 01:52 PM.
    Regards, John55
    If you have issues with Code I've provided, I appreciate your feedback.
    In the event Code provided resolves your issue, please mark your Thread as SOLVED.
    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

    ...enjoy -funny parrots-

  7. #7
    Forum Contributor
    Join Date
    08-15-2012
    Location
    Australia
    MS-Off Ver
    Excel 2016
    Posts
    349

    Re: User Passwords to view specific sheets

    It's look like you got answers on another forum;http://www.ozgrid.com/forum/showthread.php?t=194349
    Read this for cross-poster;http://www.excelguru.ca/content.php?184
    Last edited by Blokeman; 04-24-2015 at 03:24 AM.
    Please click the * Add Reputation if this helps
    If solved remember to mark Thread as solved

    "I'm glad to help and this is not meant to sound smart, but either you have super-human vision to see all those controls cleared one by one with the code I posted, or your computer is really slow."

  8. #8
    Registered User
    Join Date
    08-01-2011
    Location
    London, England
    MS-Off Ver
    Office 365 updated
    Posts
    13

    Re: User Passwords to view specific sheets

    Apologies Blokeman and thanks for sending through the guidance on this topic.

    If anyone else has this same problem, please use the link provided by Bokeman to another website where Roy has provided a solution that can be altered.

    Many thanks for your help

    Best Wishes

    Kev

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Allow users (with passwords) to view and edit multiple sheets per user.
    By tjwalsh626 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 09-17-2014, 08:38 PM
  2. Setting Up Passwords For Different Tabs--Each Person Can Only View One Tab
    By KerryFreeman in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-19-2013, 11:16 AM
  3. [SOLVED] User and passwords
    By Khail in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-01-2013, 08:32 AM
  4. Hide/unhide sheets based on user names and passwords
    By rama1209 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-23-2011, 09:11 PM
  5. specific user view
    By G in forum Excel General
    Replies: 0
    Last Post: 01-24-2006, 07:35 PM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1