Tip: Other languages are Google-Translated. You can visit the English version of this link.
Log in
x
or
x
x
Register
x

or

How to highlight / conditional formatting cells with formulas in Excel?

Supposing you have a large worksheet which contains both constants and formulas, and now you want to know the location of all the formula cells. Of course, you can select all the formulas easily and quickly by using Go To Special function. But if your data or formulas need to be changed now and then, you must apply this function repeatedly.

Here, I introduce you a better solution-- Conditional Formatting. With Conditional Formatting, you can highlight all cells with formulas and what's more, your highlighted formatting will be adjusted with your changing data.

Highlight formula cells with Define Name Formula and Conditional Formatting

Highlight formula cells with User Defined Function and Conditional Formatting

Highlight formula cells with Kutools for Excel quickly and easily


Highlight / Conditional formatting all formula cells in a workbook :

With Kutools for Excel's Highlight Formula utiltiy, you can highlight the formulas of the whole workbook with one click.

doc highlight formula-14

Kutools for Excel: with more than 200 handy Excel add-ins, free to try with no limitation in 60 days. Download and free trial Now!



Before using the Conditional Formatting, you should create a Defined Name, please do with following steps:

1. Open your worksheet and go to click Formulas > Name Manager, see screenshot:

doc-highlight-formula1

2. In the popped out Name Manager dialog box, click New button.

doc-highlight-formula1

3. And in the New Name dialog box, do the following operations:

  • (1.) Type a name for your defined name formula, in this example, I will input Formatformulas;
  • (2.) Choose Workbook from the Scope drop down list;
  • (3.) Enter this formula =GET.CELL(48,INDIRECT("rc",FALSE)) into the Refers to field.

doc-highlight-formula1

4. Then click OK to return to the former dialog and close it.

5. Then select your range or the whole worksheet that you want to highlight the formula cells.

6. Under Home tab, click Conditional Formatting > New Rule, see screenshot:

doc-highlight-formula1

7. In the New Formatting Rule dialog, click Use a formula to determine which cells to format option, and enter this formula =Formatformulas (Formatformulas is your defined name in step 3), you can change it to your own defined name. See screenshot:

doc-highlight-formula1

8. Then click Format button, set your formatting under Fill tab, see screenshot:

doc-highlight-formula1

9. And then click OK > OK to finish the operations, and all the cells with formula have been highlighted at once as following shown:

doc-highlight-formula1

Notes:

1. When you enter formulas in any of the cells which covered by the Conditional Formatting, they will be highlighted automatically.

2. After finishing the operations, you need to save your workbook as an Excel Macro- Enabled Workbook so that the conditional formatting cells are saved. And when you open your workbook next time, click Enable Content.

doc-highlight-formula1


If you don’t want to use the defined name formula, you can create a simple User Defined Function, and then apply the Conditional Formatting to solve this task.

1. Firstly, hold down the ALT + F11 keys to open the Microsoft Visual Basic for Applications window.

2. Click Insert > Module, and paste the following shorter code in the Module Window.

Function HasFormula(Rng As Range) As Boolean
'Update 20140210
Application.Volatile
HasFormula = Rng.HasFormula
End Function

3. Then save and close this code and go back the worksheet to select the range or whole worksheet that you want to highlight the formula cells.

4. Go to Home tab, and click Conditional Formatting > New Rule.

5. In the New Formatting Rule dialog, select Use a formula to determine which cells to format option, and enter this formula =Hasformula(A1), see screenshot:

doc-highlight-formula1

6. Then click Format button, and choose one color you like under Fill tab in the Format Cells dialog box.

7. And then click OK > OK to close the dialogs. And all the cells contains formula have been highlighted immediately.

Notes:

1. In the formula A1 indicates the first cell in your selected range, you can change it to meet as your need.

2. When you enter formulas in any of the cells which covered by the Conditional Formatting, they will be highlighted automatically.

3. After finishing the operations, you need to save your workbook as an Excel Macro- Enabled Workbook so that the conditional formatting cells are saved. And when you open your workbook next time, click Enable Content.


It seems the above two methods both are somewhat difficult for our Excel beginner, here, I will recommend a powerful tool- Kutools for Excel, with its multifunctional Worksheet Design feature, you can quickly highlight all formulas of the whole workbook.

Kutools for Excel : with more than 300 handy Excel add-ins, free to try with no limitation in 60 days.

After installing Kutools for Excel, please do with following steps:

1. Open the workbook which you want to highlight all the formulas.

2. Click Enterprise > Worksheet Design, and a new Design tab will be displayed in the ribbon, then click Highlight Formulas option in the View group, see screenshots:

doc highlight formula10-10
 1
doc highlight formula11-11

3. And all of the formulas within the whole workbook have been highlighted immediately. See screenshot:

doc-highlight-formula1

Notes:

1. Click the Highlight Formulas again, the highlighting will be turned off.

2. You can change the highlighting color to your like by clicking Settings under the Design tab, and then in the Design Tools Settings dialog, choose one color you like from the Formulas color section:

doc-highlight-formula1

3. When you enter new formulas in any of the cells within the current workbook, they will be highlighted automatically.

Click to know more about this Highlight Formulas utility.

Download and free trial Kutools for Excel Now !


Kutools for Excel: with more than 200 handy Excel add-ins, free to try with no limitation in 60 days. Download and free trial Now!


Related articles:

How to lock and protect formulas in Excel?

How to hide formulas not displayed in the formula bar in Excel?


Kutools for Excel Solves Most of Your Problems, and Increases Your Productivity by 80%

  • Reuse: Quickly insert complex formulas, charts and anything that you have used before; Encrypt Cells with password; Create Mailing List and send emails...
  • Super Formula Bar (easily edit multiple lines of text and formula); Reading Layout (easily read and edit large numbers of cells); Paste to Filtered Range...
  • Merge Cells/Rows/Columns without losing Data; Split Cells Content; Combine Duplicate Rows/Columns... Prevent Duplicate Cells; Compare Ranges...
  • Select Duplicate or Unique Rows; Select Blank Rows (all cells are empty); Super Find and Fuzzy Find in Many Workbooks; Random Select...
  • Exact Copy Multiple Cells without changing formula reference; Auto Create References to Multiple Sheets; Insert Bullets, Check Boxes and more...
  • Extract Text, Add Text, Remove by Position, Remove Space; Create and Print Paging Subtotals; Convert Between Cells Content and Comments...
  • Super Filter (save and apply filter schemes to other sheets); Advanced Sort by month/week/day, frequency and more; Special Filter by bold, italic...
  • Combine Workbooks and WorkSheets; Merge Tables based on key columns; Split Data into Multiple Sheets; Batch Convert xls, xlsx and PDF...
  • More than 300 powerful features. Supports Office/Excel 2007-2019 and 365. Supports all languages. Easy deploying in your enterprise or organization. Full features 30-day free trial.
kte tab 201905

Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!
officetab bottom
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.
  • To post as a guest, your comment is unpublished.
    Johan · 10 months ago
    Hey,

    ik wil een cel, welke een formule heeft, met een kleur aanduiden in functie van een andere cel die een waarde heeft.

    vb: als E10<4 dan moet F10 (welke een formule heeft) samen met E10 in een bepaalde kleur komen.

    Als ik dit doe, wordt enkel E10 gemarkeerd.


    Hoe los Ik dit op?


    Mvg
  • To post as a guest, your comment is unpublished.
    Katie Samek · 2 years ago
    I was able to follow all the below. I made a macro to do this for me, but it is not able to apply the formatting.

    My range is named, but how to I ass VBA to highlight the range with formatting. For context, I am highlighting all cells with a formula in it to be a green color. If the formula is typed over it changes colors
    • To post as a guest, your comment is unpublished.
      Natalie · 1 years ago
      This is exactly what I want to do, and the first stage (highlighting every cell with a formula in) isn't working for me either, despite following steps to the letter. Did you manage to get a solution?
  • To post as a guest, your comment is unpublished.
    SANDEEP.POLAPALLY · 3 years ago
    dear sir,

    i have a doubt ,for example in a student marks table i want the student names highlited based on the student who got lessthan 400 total marks using conditional formatting.please help me sir
  • To post as a guest, your comment is unpublished.
    Abu Belaluddin · 4 years ago
    Hi, How can I highlight cells in a row based on days of a month, for example if I need to highlight cells in increments of 1 day i.e. it should highlight each subsequent cells if 24 hrs has passed,
  • To post as a guest, your comment is unpublished.
    Jamal · 5 years ago
    Hi,
    I am trying to do conditional formatting on a cell based on another cell value which already has a formula on it. i have tried everything but i would not work. eg. cell B1 has a formula (A1+1) and i am trying to change the color of say cell D8 by using formula (=B1=21). it works fine when i remove the increment formula from B1 and enter a value manually...
  • To post as a guest, your comment is unpublished.
    Pritesh Patel · 5 years ago
    Thanks for the help.

    This is the only website where i have found complete steps