In this article, to protect cells containing formula in an unprotected sheet, we will use Data validation option.
Data validation is an awesome feature of Excel that you can use to describe limitations or restrictions on what type of data can be used in a cell. You can prevent users from entering data that is not valid. If you favor, you can allow users to enter invalid data & display a warning message when they enter data in the cell. The shortcut key is ALT+D+L.
Let’s take an example and understand how we can protect the formula containing cells.
We have data in which some cells are containing the formula for the calculation purpose. Now, we want to protect all those cells in which formulas are applied.
Follow below given steps:-
Data Validation:-
When we will enter any text in the cell, it will never change the formula and a pop up will appear.
This is the way we can protect the formula containing cells through data validation in Microsoft Excel.
The applications/code on this site are distributed as is and without warranties or liability. In no event shall the owner of the copyrights, or the authors of the applications/code be liable for any loss of profit, any problems or any damage resulting from the use or evaluation of the applications/code.
I have tried this "=False" in formula bar and it works. Thanks a lot for your kind help
Thank you for sharing this knowledge of yours. It is very practical and useful for my purpose.
Thanks for your help, How can I remove the Data validation if I wish to, I succeeded to protect my formula using the Data validation, but how do I discard this protection?
This did work for me for formulas and text fields, and allows me to have an Unprotected worksheet in a Shared workbook... so users can sort a dynamic data range without the risk of deleting formulas or text. Note that locked cells in a protected worksheet cannot be sorted in a Shared workbook, so this is a better option in my case since I can leave the cells unlocked without risking deletion by users.
I initially entered "=" and "FALSE", but when I checked the data validation settings, it only shows "FALSE" in the Formula box.
“=FALSE” does not work
To prevent deletion of formula, change the validation formula to "=FALSE" and uncheck the "Ignore Blank" option. BAM! No more deleting formulas.
Hi Reighley,
Thanks for great tips; But with Data Validation anybody may delete the formula. So is there any other more safe option and how can we hide our formula which is clearly visible in Data Validation.
Pls. Help.............
Fabulous! I have been trying to figure out how to protect formulas but allow them to me copied when adding new rows to a costing template.
How can this Data Validation method be modified so that the formula cannot be deleted?
It doesn't allow the formula to be changed or typed over, but it does not prevent the formula from being deleted from the cell.