Conditional Formatting based on Checkbox

chester1993

New Member
Joined
Jan 26, 2016
Messages
40
Hello all.

I have Sheet1 where I want to put data on cells B2:E20. I want to place a Conditional Formatting on these cells.
Basically, I want to fill the cell if a data is entered - doesnt matter what data, I will put something in that cell.
However, the fill color on the cell will be dependent on my 2 form checkboxes.

Checkbox1 - Green
Checkbox2 - Blue

I have tried the link cell - True or False method. But, I cant seem to make it work. When the checkbox is tick, all cells (B2:E20) will be filled instead of the only cell that I put data in.

I hope someone can help me. Thank you!
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
What is the linked cell of both checkboxes?
What is the CF condition?
 
Upvote 0
Hi @GraH .

Checkbox 1 - linked to A21
Checkbox 2 - linked to A22.

For CF condition, basically any value on that cell. It could be number, could be letter. What matters is the cell will be filled if either of checkboxes is ticked.

Thank you!
 
Upvote 0
Are you after this then?
Select B2 and then create the conditional formatting formula.
Book1
ABCDEFGH
1
2av1>
3
4
5
6x
7
8
9
10z
11
12
131
14
154
16
174
18
19
20
21TRUE
22FALSE
23
Sheet1
Cells with Conditional Formatting
CellConditionCell FormatStop If True
B2:E20Expression=AND(B2<>"";$A$22)textNO
B2:E20Expression=AND(B2<>"";$A$21)textNO

1598699515929.png
 
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,240
Members
452,621
Latest member
Laura_PinksBTHFT

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
Back
Top