Protect Cells from Any Unauthorized Changes in Excel

Protecting your Excel Files from any unauthorized changes is crucial.

When you email or share your Excel files with others, there are always chances that they may change some key information, that shouldn’t have been changed.

This can happen because, by default, all cells in Excel are available for modifications by anyone having access to the Excel file.

But the strange thing is that if you were to check Excel’s cell protection setting under Format Cells, you’d find that each cell is marked as Locked.  However, Microsoft is quick to inform you that

Locking cells or hiding formulas has no effect until you protect the sheet.

Quite a strange setting, I believe. However, you can use this setting to your advantage.

Scenario: Preparing a Protected Travel Expense Claim Form in Excel.

Let’s say you are creating a Travel Claim Form for all staff to use in the company when they use their own transport for office meetings or customer visits.

You’d only want the staff to key in their travel expenses, dates, and the type of expenses. You wouldn’t want them to modify the rate which you use to calculate the claim amount. However, you would still want yourself or HR manager to be able to adjust the rate periodically, based on the policy.

To achieve this, you will have to create an Excel Spreadsheet, with careful consideration of the data protection. Your Excel file must have:

  1. Some cells are protected completely (no changes allowed by anyone) These could be formulas and any master data like names of departments, cities etc. More like master data that does not change often.
  2. Some cells that can only be modified by you or HR. These could be the Rate of reimbursement etc. You could even set a password to allow only authorized people with the right password to key in this information.
  3. Some cells that anyone can modify. These would be the cells where the staff is going to key in their expenses. Mostly, such cells would be the ones accepting the data entry values only.

Here are the detailed steps that you can take to protect the information and make a spreadsheet that everyone can use, without fear of getting inadvertent changes to the file, and maintaining full privacy and security.

Step 1: Unlock all Cells in your Excel Template.

To do this, Select All Cells (you can press Control A or press the small rectangle above row 1 on the top-left area of the spreadsheet. Once all cells are selected, right-click to activate the menu, and go to Format Cells. Shortcut is Control 1 for this option.

Now move to the Protection tab, and uncheck the Locked checkbox.

Click OK and come out of this popup. Now all cells are unlocked.

Step 2: Lock the Calculations & Totals Row/Columns

Select the cells that have any calculations. To select multiple cells, highlight them, and hold the Control key to multi-select several formula and total ranges.

Now go to Format Cells by right-clicking, or press Control 1 again. This time, you can check both checkboxes on the Protection Tab. Lock and Hide the formulas and cells completely.

Step 3: Select Cells That can only be modified by authorized Users

Finally, it is time to select the cells that need to be protected from unauthorized changes. So select those cells, again by using the Control Key to multi-select the cells.

Once the cells are selected, go to Format Cells > Protection Tab, and Lock them. Click OK.

Step 4: Set a Password to cells that only an Authorized User can modify.

Go to Review Tab on the Excel menubar. Select Allow Users to Edit Ranges, from the Changes group on this menu.

Click New, and key in a name for the cell range. Set a password that will be required to be keyed in whenever anyone tries to change such cells. You have to key it in 2 times to confirm the password.

Step 5: Protect the Sheet

The previous 4 steps will have no effect until you protect the entire sheet.

To do so, go to Review > Protect Sheet.

You can then, optionally, set a password. Although I say optionally, I’d recommend that you definitely do it as a best practice. otherwise, any user can modify your template, simply by unprotecting the worksheet, make any change, and protect it again.

You will be required to key in the password twice, to confirm that it is the correct password.

Step 6: Test the Protected Sheet, and deploy it.

Now you are ready to test your protected Excel Template.

Users should be able to key in their particulars, expense, mileage etc. But they would not be able to see the formulas behind the calculations.

Neither will they be able to edit or change these totals.

And best of all, they can never edit the reimbursement rate. Even if they click it inadvertently, Excel will ask them for a password.

As for HR, they should have the password set by you. With this password, they should be able to edit the reimbursement rate, and then save the template for use in the future, with the newly revised rates.

Voila, quite a sophisticated Excel template, with worksheet protection, hidden formulas and authorised user-editable cells created in no time.

Give it a try. I’m sure you’d love this simple method to protect your data files from unauthorised changes.

Written By Vinai Prakash,
Founder of ExcelChamp.Net & Intellisoft Systems
Vinai has over 30 years of experience working with spreadsheets and teaches Excel, Advanced Excel, Excel Data Analysis, Excel Dashboarding Techniques at Intellisoft Systems in Singapore, and online at ExcelChamp.Net.

 

 

 

 

Show Buttons
Hide Buttons