Conditional Formatting - fill color based on another cell color or font format?

lichldo

Board Regular
Joined
Apr 19, 2022
Messages
65
Office Version
  1. 365
Platform
  1. MacOS
Hello, I am trying to make a table to input a set of daily data, so I have my dates (using a formula) as the top row, and have applied conditional formatting so that the WEEKEND dates are in blue and have strikethrough text. I would like to carry that formatting down to all the rows beneath each weekend date so that it's clear data won't be needed on those dates. Is there a way to automatically carry it down, or even add an "N/A" in the columns below the weekend dates? I would need it to go down to row 29, and then I have my next month table starting.

Screen Shot 2022-07-11 at 2.33.47 PM.png
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
If you already have a Conditional Formatting formula that does this for row 1, it is easy to extend it for the other rows.
Just select all the rows you want to apply it to, and lock the row reference in your Conditional Formatting formula with a "$", i,e, A$1

Regarding the "N/A", Conditional Formatting can only affect formatting, not cell values.
You would need to do that with a formula, VBA, or simply manually enter it in for the first row of data (row 2), and copy down as far as you need.
 
Upvote 0
If you already have a Conditional Formatting formula that does this for row 1, it is easy to extend it for the other rows.
Just select all the rows you want to apply it to, and lock the row reference in your Conditional Formatting formula with a "$", i,e, A$1

Regarding the "N/A", Conditional Formatting can only affect formatting, not cell values.
You would need to do that with a formula, VBA, or simply manually enter it in for the first row of data (row 2), and copy down as far as you need.
My current conditional formatting formula is =WEEKDAY(B1,2)>5 and applies to range $B$1:$AF$1
My first date starts in B1

So how would I extend down to row 29?
 
Upvote 0
Clear you current Conditional Formatting rules.
Then select the range B1:AF29.
Then enter the Conditional Formatting formula:
=WEEKDAY(B$1,2)>5
(this will allow the columns to float, but locks in row 1, so that EVERY cell in your selected range will look at the date in row 1)
And then choose your formatting options.

If you aren't already familiar with Absolute, Relative, and Mixed cell references, I highly recommend reading this article here: Absolute, Relative, and Mixed Cell References in Excel
 
Upvote 0
Solution

Forum statistics

Threads
1,215,865
Messages
6,127,400
Members
449,382
Latest member
DonnaRisso

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