+ Reply to Thread
Results 1 to 5 of 5

Prevent other user opening excel file.

  1. #1
    Forum Contributor ebin charles's Avatar
    Join Date
    Dammam, Saudi Arabia
    MS-Off Ver
    Microsoft Excel 2010

    Prevent other user opening excel file.

    Dear All,

    This is kind request that is there any way to prevent other user/computer opening my excel files.
    (based on the username of the computer).

    Some confidential files need to be maintain privacy.

    Is there any solution? Please a help.


  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    Hamburg, Germany
    MS-Off Ver
    2019 on Win10 (desktop), 2019 on Win11 (notebook)

    Re: Prevent other user opening excel file.

    Hi, ebin charles,

    Some confidential files need to be maintain privacy.
    Do not use Excel!

    You could use Environ("ComputerName") or Environ("Username") in ThisWorkbook and Workbook_Open and close the workbook if they do not match but this needs Macros to be activated.

    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  3. #3
    Administrator FDibbins's Avatar
    Join Date
    Duncansville, PA USA
    MS-Off Ver
    Excel 2000/3/7/10/13/16/365

    Re: Prevent other user opening excel file.

    Excle security is not the best, but you could save the workbooks as password protected. You could then give the password to only those that need to be able to open those files.

    Another option, if you are on a network, would be to get the Admin to set up a folder for those files that only designated users have access to. This is not an excel setting, but something the NW admin would need to do
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you


  4. #4
    Forum Guru Kyle123's Avatar
    Join Date
    MS-Off Ver
    365 Win 11

    Re: Prevent other user opening excel file.

    Put a password to open on them and don't put them in a shared place

  5. #5
    Forum Guru Winon's Avatar
    Join Date
    East Rand, R.S.A.
    MS-Off Ver

    Re: Prevent other user opening excel file.

    Hello ebin charles,

    No matter what you do with your Excel Workbook, i.e., Protection, Passwords, VBA Protection, and whatever, it can be opened in quite a few other platforms or programs like Front Desk or Open Office, just to name a few!

    I support what HaHoBe said, "Do not use Excel!"

    FDibbins also states that "Excel security is not the best..."

    It would seems that you will have to use every available Excel and or VBA Protection available, and then rely on the integrity of the user!

    Please consider:

    Be polite. Thank those who have helped you. Then Click on the star icon in the lower left part of the contributor's post and add Reputation. Cleaning up when you're done. If you are satisfied with the help you have received, then Please do Mark your thread [SOLVED] .

+ 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. How to prevent opening a blank excel file
    By st24961 in forum Excel General
    Replies: 1
    Last Post: 05-09-2007, 10:22 PM
  2. [SOLVED] Prevent Excel from going online when opening html file
    By G.Mueller in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-25-2006, 03:30 AM
  3. How to prevent user to copy excel file to their own pc
    By shirley_kee in forum Excel General
    Replies: 4
    Last Post: 04-07-2006, 11:24 AM
  4. restrict a user from opening a dbf file from excel?
    By WyldX in forum Excel General
    Replies: 0
    Last Post: 01-18-2006, 09:45 AM
  5. how do I prevent a file from opening if user has disabled macros?
    By mwh1107 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-26-2005, 07:05 PM


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