How to color formula cells in Excel automatically
Formulas in Excel or functions in Excel like Vlookup and SUM functions help to calculate data or process tables more easily and quickly. And of course, when processing the data table, it will need manipulations to check operations, or some cases we need to lock Excel formulas to avoid editing. However, with long data tables, finding the correct formula cell is relatively time consuming. If so, the user can color the Excel formula cell automatically, quickly identify which data areas in the table use the formula for faster processing. The following article will guide you how to color formula cells in Excel
1. How to color formula cells in Excel automatically
At the Excel table interface to find the formula cell, we click on the Developer tab and then select Visual Basic as shown below.
Display the VBA interface, click Insert and select Module to display the code input interface.
Next, you enter the code below to filter and search for cells that use formulas in the table.Notice at the line of code Rng.Interior.ColorIndex = 36 , the number 36 is the color code so we can change to another color code if we want to use another color. Click Run to run the code.
Sub SelectFormulaCells() 'Updateby20140827 Dim Rng As Range Dim WorkRng As Range On Error Resume Next xTitleId = 'KutoolsforExcel' Set WorkRng = Application.Selection Set WorkRng = Application.InputBox('Range', xTitleId, WorkRng.Address, Type:=8) Set WorkRng = WorkRng.SpecialCells(xlCellTypeFormulas, 23) Application.ScreenUpdating = False For Each Rng In WorkRng Rng.Interior.ColorIndex = 50 Next Application.ScreenUpdating = True End Sub
Next, you localize the data in the KutoolsforExcel dialog interface and click OK to color.
The results of the cells that use the formula are colored as shown below. The color depends on the color code the user entered in the code.
2. Localize formulas in Excel
If you do not want to color in a table, just quickly highlight the range of data using the formula, just use the Go To Special tool .
We highlight the whole table and press the F5 key to open the Go To dialog box, then click Special to expand the custom.
Next to display the table, tick Formulas and click OK to identify the formula.
Then the data area using the zoned formula is identified as below.
See more:
- 4 basic steps for alternating coloring of lines in Microsoft Excel
- 4 basic steps to color alternating columns in Microsoft Excel
You should read it
- Lock cells with formulas in Excel - Lock and protect cells containing formulas in Excel
- Guidelines for importing Chemistry formulas in Excel
- How to hide formulas in Excel
- Instructions on how to copy formulas in Excel
- How to create an Excel formula in Notepad ++
- How to Lock Cells in Excel
- How to Copy Formulas in Excel
- How to calculate and color blank cells in Excel
May be interested
- Study online on e-Learning lecturesthe e-learning lecture store under the ministry of education and training provides courses with various levels and subjects for students or teachers to have more teaching and learning materials.
- How to edit photos in Google Slidesimages inserted in google slides have tools for editing such as cropping, changing image colors, ... or adding effects to images.
- How to add synonym dictionary to Google Docsif you use google docs to create your documents, you have a few great thesaurus options, from basic built-in dictionaries to add-ons with extra features. here's how to use a thesaurus in google docs.
- How to choose the print area on Google Sheetsselecting a print area in google sheets will help you choose to print the content you want, instead of printing the entire data content.
- How to create a Multilevel List in Google Docsmultilevel list in google docs is a multi-level list when users want to create many different content indexes.
- How to write notes on Easy Sticky Notes Pro Windows 10notes application easy sticky notes pro has added syncing feature to onedrive for users to access whenever they want.