+ Reply to Thread
Results 1 to 7 of 7

Unhide hidden Workbooks in a specific directory by password

  1. #1
    Registered User
    Join Date
    01-07-2013
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    65

    Unhide hidden Workbooks in a specific directory by password

    Hi All,

    I have about 200 workbooks all in same directory. The reason why they are hidden is that each workbook should only be accessed by their specific users.

    I need a macro to run on a separate workbook (call it log in workbook and this work book is not hidden - the only unhidden workbook in that directory -) for user to enter password to unhide specific file.

    All file names with extensions are stored in "log in" workbook Sheet1 (Column A Workbook name and Column B Password).

    I am also aware that this is not the most secure way to deal with this issue and an average computer user can easily access any file but I am fine with that. - All our users are well below average lol :-) -

    Any help would be greatly appreciated.

    Ege

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Unhide hidden Workbooks in a specific directory by password

    You'll need to use the FileSystemObject and look at the attributes of each of the files and change

    Constant Value Description
    Normal 0 Normal file. No attributes are set.
    ReadOnly 1 Read-only file. Attribute is read/write.
    Hidden 2 Hidden file. Attribute is read/write.
    System 4 System file. Attribute is read/write.
    Volume 8 Disk drive volume label. Attribute is read-only.
    Directory 16 Folder or directory. Attribute is read-only.
    Archive 32 File has changed since last backup. Attribute is read/write.
    Alias 64 Link or shortcut. Attribute is read-only.
    Compressed 128 Compressed file. Attribute is read-only.
    Hope this helps

    Sometimes its best to start at the beginning and learn VBA & Excel.

    Please dont ask me to do your work for you, I learnt from Reading books, Recording, F1 and Google and like having all of this knowledge in my head for the next time i wish to do it, or wish to tweak it.
    Available for remote consultancy work PM me

  3. #3
    Registered User
    Join Date
    01-07-2013
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    65

    Re: Unhide hidden Workbooks in a specific directory by password

    Thanks Nathan,

    All the files are hidden, not archived, not compressed, no system files and all .xlsx files but unsure what you mean?

    It should be a macro scan through all xlsx files including hidden xlsx files in that directory and unhide the one if the correct password is entered.

  4. #4
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Unhide hidden Workbooks in a specific directory by password

    Google the filesystem object






    Constant Value Description
    Normal 0 Normal file. No attributes are set.
    ReadOnly 1 Read-only file. Attribute is read/write.
    Hidden 2 Hidden file. Attribute is read/write.
    System 4 System file. Attribute is read/write.
    Volume 8 Disk drive volume label. Attribute is read-only.
    Directory 16 Folder or directory. Attribute is read-only.
    Archive 32 File has changed since last backup. Attribute is read/write.
    Alias 64 Link or shortcut. Attribute is read-only.
    Compressed 128 Compressed file. Attribute is read-only.

  5. #5
    Registered User
    Join Date
    01-07-2013
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    65

    Re: Unhide hidden Workbooks in a specific directory by password

    Thanks again!!!

    I did Google it and I do not understand a thing.

    If I had the required programming knowledge to to be able to sort this by googling filesystemobject I wouldn't have come here.

  6. #6
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Unhide hidden Workbooks in a specific directory by password


  7. #7
    Registered User
    Join Date
    01-07-2013
    Location
    England
    MS-Off Ver
    Excel 2007
    Posts
    65

    Re: Unhide hidden Workbooks in a specific directory by password

    For anyone if they need anything something similar in the future here is my solution works like a charm without making something simple a major task :-)

    2 different solution one been hyperlink formula and other is macro (Macro1)

    You don't need fileobject or whatever or hrs of google search for something you have no idea what it is.

    You can make password tabs .veryhidden.

    Please Login or Register  to view this content.
    Link to file is on B9 of active worksheet and you can amend the formula in B9 if you want to use the code as currently it is set as it is not using the code but link in the file.

    Regards,

    Ege
    Attached Files Attached Files

+ 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. VBA Startup Password to unhide specific sheets
    By newbie4 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-18-2013, 07:09 PM
  2. Assigning Object a Macro to unhide hidden tabs with specific text
    By alorro3 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-02-2012, 12:26 PM
  3. Split data into multiple sheets and to be hidden and password protected to unhide
    By anchuri_chaitanya in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-30-2012, 11:36 PM
  4. different password to unhide the hidden sheets.
    By Rahul Nagar in forum Excel General
    Replies: 6
    Last Post: 11-24-2008, 01:56 PM
  5. Unhide 1 specific hidden column
    By Frustr8ed! in forum Excel General
    Replies: 2
    Last Post: 03-06-2007, 04:52 AM

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