Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

There is an Excel file which I import from a specific network path or local path, and that Excel file is exported from another vendor aplication. The problem is that the Excel file is editable.

Is there any way I can lock the Excel file or make it un-editable? It would be acceptable to apply this lock and/or remove the editability from the containing folder as well.

share|improve this question

migrated from May 14 '12 at 12:06

This question came from our site for professional and enthusiast programmers.

Have you changed the permissions to the file on the machine where it is located? i.e. File properties - check 'Read only'? – rudeovski ze bear Apr 24 '12 at 3:12
ya that is not the solution because any user can change the property setting. i want some thing i can do it by code. or to lock the File. – vish's Apr 24 '12 at 4:35
How is the file being exported? User initiated from vendor application? – Pynner Apr 24 '12 at 11:58
its been exported to a specfic shared folder from vendor apllication. – vish's Apr 24 '12 at 13:18

An Excel spreadsheet can have a password to modify. Under Save, click on the Tools dropdown and then General Options. If you implement this, the spreadsheet can not be modified unless you know the password.

modify password

share|improve this answer

You can make cells uneditable in excel, by using the "protect" option.

Could any of the following links help you?

Link 1 Locking cells

Link 2 generated by

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.