• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 200
  • Last Modified:

Conditional Formatting in Excel


I would like to apply a format of bold and red font to column "B" in Excel if the value in column A on the same rowl has the value "Count".

"Count" was obtained by subtotal function in Excel.  I am trying to bold and put in red font the results from the subtotal.

Is there a way to do this?
  • 2
1 Solution
Glenn RayExcel VBA DeveloperCommented:
Yes you can.

I assume you're using Subtotals to count the number of values in each subsection.  You can create a conditional format to check for "Count" in column A like so:
conditional formatting on "Count" in subtotals
You'll just highlight all the cells in column B that apply, add the conditional formatting rule as shown above and then note the formatting change (bold, red font).

NOTE:  if you remove/re-add subtotals, the formatting will likely not appear.  You'll have to edit the conditional formatting rule again to ensure that it has the formula =RIGHT($A2,5)="Count"

moriniaAdvanced Analytics AnalystAuthor Commented:
I had to change $A2 to $A1  sorry for the typo.
Glenn RayExcel VBA DeveloperCommented:
FYI:  I had to use $A2 in my conditional formatting formula because my range to apply the rule started in the second row (B2:B27).

Nevertheless, I'm glad it works for you.


Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now