Conditional format dates to display weekends

starsky

New Member
Joined
Oct 20, 2002
Messages
3
I have a spreadsheet that contains a calender at the top. Pretty much every day from sept 1 to may 1. Column A contains projects I'm working on. I want to map out when i'm going to do each job and how long it should take.

My question is how do I make a conditional fomat such that the weekend days are highlighted in a different color? Basicaly, how do i get excel to recogonize a weekend from a weekday.
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
You could use the formula
=WEEKDAY(A1,2)>5

where a1 is the cell of interest as your conditional formatting formula.
 
Upvote 0
Hi: Welcome to the board.

Assume you dates are in row 1. Select Row 1 by clicking on the number 1 to the left of column A. Now choose Format>Conditional Formatting. Select the formula is option. Enter =WEEKDAY(A$1,2)>5. Choose a format. Click OK. This will format Sat. and Sun. dates
 
Upvote 0
My dates start in cell B2 and go from there.

Does that formula work for dates in the form 10/21/02?

I'm assuming the weekday function evaluates the day of the week, so monday would =1, tuesday =2, and so on and so fourth.. correct?
 
Upvote 0
The display format of the date does not matter. Excel works with the serial number for the date. You are correct in your assumption of the WEEKDAY function. The Second argument (The 2 after the date reference) assigns Monday as Day 1. If the second argument is omitted, the default is 1, which makes Sunday Day 1

So, select all you cells with dates in Row 2 beginning at B2. The formula is =WEEKDAY(B$2,2)>5
 
Upvote 0

Forum statistics

Threads
1,214,617
Messages
6,120,541
Members
448,970
Latest member
kennimack

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