Conditional formatting: Formula to change cell colour based on their respective columns

atisyam

New Member
Joined
Sep 19, 2018
Messages
37
Hello. In my case I have 2 rows and all columns are affected. The 2 rows are Row 2 and Row 3.What I want is that whenever cell A2 contains "MAN", then cell A3 changes to yellow. Then similarly, whenever cell B2 contains "MAN",then cell B3 changes to yellow. So the cells in row 3 will change colour respective to their alphabetic column from row 2. Therefore, I do not want cell A3 to change yellow if cell B2 contains "MAN".
So is there a formula that I can use for conditional formatting that I type once for the first cell and can be applied to all rows?

Currently, I am doing cell by cell. So I got to cell A3, B3, C3..... and then I type
Code:
=$D$2="MAN"
(this code example is for cell D3).

Hope to get help. Thanks.
 
Last edited:

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.

jtakw

Well-known Member
Joined
Jun 29, 2014
Messages
7,245
Office Version
  1. 2016
Platform
  1. Windows
Hi,

Select A3 and drag across the rest of your range for CF, CF, use formula, and enter

=A2="Man"

Choose Format.
 
Last edited:

jtakw

Well-known Member
Joined
Jun 29, 2014
Messages
7,245
Office Version
  1. 2016
Platform
  1. Windows
You're welcome, thanks for the feedback.
 
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,163,595
Messages
5,832,634
Members
430,149
Latest member
amitk1

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top