See how to apply Excel conditional formatting to dates. Learn how to use formulas to highlight weekends and holidays, format cells when a value is changed to a date, shade upcoming dates and delays, conditionally format dates based on the current date, and more. Continue reading
Comments page 35. Total comments: 1243
Hi need help how to resolve this formula... it always end in #VALUE! error because of N/A and A word... Thanks!
=IF(I42=3,I42*3*12,IF(I42="N/A",0,IF(I42="A",0))))
Hi
I have been trying out the formulas but i just cant get what i wanted. im trying to keep track on deliveries and need a warning before the actual delivery date.
Cell A1 = todays date
i want it to be:
orange : 15 days before date(or any number of days i can modify to)
yellow : on the day itself till
red: after 15 days onwards
thanks.
Hi Joey,
Select the dates you want to format, say in column B, and try creating the rules with the following formulas, where B2 is the top-left cell of the selected range:
Yellow: =AND($B2>=$A$1, ($B2-$A$1)<15)
Red: =$B2-$A$1>=15
Orange: =$A$1-$B2=15 - exactly 15 days before the date
or
Orange: =AND($B2<$A$1, ($A$1-$B2) <=15) - from 1 to 15 days before the date
wonderful. perfectly working. thanks alot!
Hi
I have a date in Cell c2, I would like cell g2 to have a red icon appear when todays date is 49 years and 6 months after the date in c2.
I would also like cell h2 to have a red icon when todays date is 59 years and 6months after the date in cell c2
Hello
I want to highlight my cells in different colours depending on the date. For example (and I'm using British dates sorry) if I have cell 1A with a date 17/10/2014 I would like it to become yellow three months after the date and red six months after the date.
Thankyou very much
Hello Finlay,
Sorry, I don't know a way to calculate exactly 3 or 6 months because the number of days varies from 28 in Feb to 31, say, in Dec.
Instead, you can highlight dates based on the number of days after a certain date. For example:
Red (after 180 days): =TODAY()-$A2>=180 (it should come 1st in the rules list)
Yellow (after 60 days):=TODAY()-$A2>=60
Hello,
I am trying to colour code for various dates and can't seem to get the formulas to work. The intent it to show any date that is equal to today (or in the past) as green, dates within the next 30 days as yellow, dates 31-60 days as orange, and anything 61 days or longer as red. I have tried creating a new spreadsheet as well as leveraging an existing one, and can't get the formulas you show above to work as a test. Any advice and assistance would be greatly appreciated.
Hello Cody,
Try creating the rules with the following formulas (assuming that your dates are in column A and row 2 is the first row with data):
Green: =$A2<=TODAY()
Yellow: =AND($A2>=TODAY()+1,$A2<=TODAY()+30)
Orange: =AND($A2>=TODAY()+31,$A2<=TODAY()+60)
Red: =$A2>=TODAY()+61
1) How do you copy an upcoming date to a different cell from a series list of 26 Dates ie starting from a set date (28/7/2015 – 30/6/2015, cells B2:B27) and showing the next highlighted upcoming date in the series list and only that date (ie every 14 days from starting date (say 14/7/2015 showing a highlighted 28/7/2015 in cell A3) then show the following next date in the series list (12/8/2015 again in A3) when the preceding next date in the series list is reached (28/7/2015 in A3).
Can someone help me with the formula of picking the highest number settlement on a weekly basis with data that shows multiple amounts settlemend on a daily basis
Hi Sam,
Please give us more details, i.e. what columns you have and what kind of values they contain (data sample would be even more helpful), and will try to help.
I have a spreadsheet with a constant date in D8. Then I have dates calculated based upon that date. I need a formula that counts 10 days from that date, but if it falls on a Saturday or Sunday, then I need Monday's date to appear.
I will also have to work in a holiday table so that if it falls on a holiday, then the next day after the holiday should appear.
Might you help?
Hello Monica,
You can use the following WORKDAY.INTL function:
=WORKDAY.INTL(D8,10,1,A17:A30)
Where A17:A30 is the range with your holiday dates.
You can find more information about the WORKDAY.INTL function in this article:
https://support.office.com/en-US/Article/WORKDAY-INTL-function-0979878c-f476-4dc7-aa81-47111caa9c8a?ui=en-US&rs=en-US&ad=US
In some Excel work sheets i am trying to insert rows, but the insert row option is disabled, but the option is enabled on on some some sheets. whats the probelm?
Most likely these worksheets are protected. To check this, select the sheet, then go to Review > Protect Sheet.
n excel file, when i am trying to move one sheet from one file to another excel file it shown a message as
"A formula sheet you want to move or copy contains the name 'sss', which already exists on the destination worksheet. Do you want to use this version of the name?
* To use the name as defined in the destination sheet, click yes.
* To rename the range referred in the formula or worksheet, click no, and enter a new name in the conflict dialog box."
it ask the same question 20 to 40 times to move a sheet.
and after move the sheet and make changes and save it with another file name and close it. when i open the same file the format totally distrubed just shown text with format.
Sorry, I've never run into a similar issue and therefore cannot advise anything.
In excel file, when i am trying to move one sheet from one file to another excel file it shown a message as
"A formula sheet you want to move or copy contains the name 'sss', which already exists on the destination worksheet. Do you want to use this version of the name?
* To use
Hi,
Thank you for the great assistance you all are providing in this blog.
My question is, I have a column in excel that contains (varying dates in certain cells and blank cells with dates yet to be entered).
I am hoping to create a formula for the entire column that initiates a green fill in the cell that contains a date (30 days after the date range specified). I hope this makes sense.
Your advice would be greatly appreciated.
Kind Regards, Paul
Ma'am,
I am trying to highlight last month, this month, and next month with various colors. For instance, last month would be black filled, with bold white font. This month will be red filled with normal font, and next month would be filled yellow with normal font. I was using the conditional formating of "last month/this month/next month" but it is highlighting things from last and next year. How can i achieve what i am trying to do? My dates show just the month and year. i tried to use the less than "=NOW()+ 30" and equals to "=NOW()". Which is working, however, i do not know how to highlight for the previous month. Any help is appreciated.
-CTR2
Hello John,
Please use the following formulas:
This Month
=month(A2)=month(today())
Next Month
=(month(A2) + 1)=month(today())
Previous Month
=(month(A2) - 1)=month(today())
Hi,
I am trying to create conditional formatting that will show 30 days before training will be required again on an annual basis.
In cell B2 (C2, D2, etc.) I have the date that training took place. The next scheduled training for each training type would be 1 year later. 30 days prior to the 1 year expiry, I would like the date to turn red or the cell fill to be red so it will highlight that re-training is going to be required soon.
Is this possible to do? Thank you for your help.
Employee Name H&S at Work WMHIS
XXXXXX 05/05/14 02/07/14
I am also trying to create conditional formatting that will show 30 days before training will be required on an annual basis nut for mine training re-certification isn't a year from the date taken it is June 15th of every year. Is it possible to make a formula for this. My boss does not want expiry dates on spread sheets she just wants dates to turn red a moth before re-certification is required.
Is this even possible? Thank you
Hello Jane,
Select all your columns with dates and use the following formula for your conditional formatting rule:
=AND(TODAY()-B2 < 366, TODAY()-B2 > 336)
Hi Dear,
I want col S(Fee defaulter) to be
1) Red fill
if col E(Ending date) is over and Col Q(remaining Fee is greater than zero).
2)and want light red fill
if Col E(Ending date) is today and Q(remaining Fee is greater than zero)
3)and if both the conditions are not met then want green fill
Thanks in advance
It works! Thank you very much! I tried other methods shown on other sites with no success. I appreciate your assistance.
Hi, I have a date in A1 and a date in B1. How would I highlight B1 IF its date occurs after (or more recent than) the date in A1? I assume you could use conditional formatting for this, but I'm unsure of the formula. Thanks.
Hi Eunice,
Try creating a conditional formatting rule for cell B1 using this formula =$B1>$A1
If you need to highlight other cells in column B as well, select them all before creating the rule.
Hi,
I've been trying to modify the formula based on your Example 2 but I still failed. Scenario: I want to highlight the cell in red if Status (Column C) is not "Closed" and the Due Date (Column M) is already exceeded. For example, Status is "In Progress" and Due Date is 10-Sep-14 but today is already 25-Sep-14. So, the formula I used was this: =AND($M2:$M500>DATEVALUE(M),$C2:$C500”Closed”) I have also formatted the Column M to be in Date format.
So what went wrong? Hope you could explain. Thank you very much!
Hello Perrin,
In conditional formatting, the formula is written for the top-left cell of the range to which you apply the rule. And Excel adjusts the formula for all other cells correctly, like when you copy the formula to other cells manually. So, most likely you need the following formula:
=AND(TODAY()>$M2, $C2<>"Closed")
Dear Madam,
Please suggest me conditional format as the date and day increase(changes) day by day i need to change the date and the day simulteneously
Hi - I just want to highlight any overdue date. The built in rules pick up yesterday, last week or last month but miss the ones that are 2 weeks ago but still this month! (ie first week of September). Can I amend the built ins so it just picks up all dates over due but ignores cells with other data like names etc?
Hi, I am currently setting up a spreadsheet on when certain places are being worked over the year. I have done conditional formatting for my other topics but I need it to show up late and do not know how to do it.
thanks,
leanne
I have lost the formula I inherited. We have an archive column and when some-one puts a date in this column it shades the whole row grey.
I cannot see where the original formula was nor how to put it back.
I want to addition in years only and no need to change month and days, please help me.
Hi,
I am making a spreadsheet for an apartment complex. I need a whole row to be highlighted red when the date in the corresponding cell in column (F), which marks when the lease ends, is this month of this year. I also would like to do the same thing but highlight the row yellow if the same corresponding cell is next month of this year. I've tried many formulas but I can't seem to get it to work. Could you help me?
Thanks!
Hi,
Just needed some help with conditional formatting. I have two columns both with dates - Column A and B. I want to highlight only the dates in B which occur before the dates in A. (e.g. if B is 4/30/2014 and A is 5/30/2014, then highlight cell B; if B is 5/24/2014 and A is 4/25/2014, do not highlight cell B.) Is that possible?
Hi Lawrence,
You can create a rule for column B with the same formula that is used for comparing numbers:
=$B2<$A2 (assuming that your table has headers and row 2 is the top row with data)
thank you your great!i have been looking everywhere for a solution
Hi,
i was wondering how can i create an excel with specific days of a week that can be repeated for a few months?
I want to create an attendance roster for Tuesdays and Thursdays for a specific date range.
thank you
Hi,
It's not quite clear how you define the Date range. The simplest variant is to write initial Tuesdays and Thursdays in one column or row, and then insert the formulas below.
If your dates are in two columns:
=A2+7
=B2+7
If the dates are in one column:
=A2+7
=A3+7
Format the cells with formulas as dates (press Ctr+1 and select Date from the Categories menu). Then copy the cells with formulas down the column till the result goes out of your Date range.
If u can please help me out of this matter. i want to put a formula that puts the expiry date of 1 year counting 365 days. i.e. if a date 01-01-2014 is written in cell(A) and i wish to have the date exactly after 1 year (365 days)in Red. URGENT PLEASE
Hello Imran,
You can use this formula to get the expiry date:
=DATE(YEAR(A2)+1,MONTH(A2),DAY(A2))
Where A2 is the cell with the original date.
I have the same problem and this formula isn't working. any other suggestions?
Many thanks
Hello Beckie,
I think I did not make myself clear in the previous response, my apologies. The above formula calculates the expiry date based on the value in cell A2. To highlight the expired dates, you can create a conditional formatting rule with this formula:
=TODAY()>$A2+365
Please see the results in this sample worksheet. If you are looking for something different, please clarify.
Hi Svetlana,
I am trying to recreate the above response to highlight the expired dates. I used conditional formatting using your formula =TODAY()>$A2+365 and this indeed worked. However, this only worked on the specific cell "A2." I'm trying to have the entire column checked for dates that are a year old. I tried highlighting the entire column but I was not successful. If you can please assist I would greatly appreciate it. Thanks!
I have a spreadsheet that has a date in column A1 - it is a today date formula.
I then have dates from Jan 2014 - May 2015 shown as each day (roster schedule), I have conditional formatting set up within the spreadsheet for various schedules (O/T/ leave etc) however I am wanting to highlight a single column based on what today's date is so "today" is easier to find when scrolling back and forward organising the schedule.
Any suggestions?
Hi Sarah,
I believe it will be easier for us to suggest a solution if we can see your data structure and the formulas you are currently using. If you can send me your sample workbook at support@ablebits.com along with the result you are trying to achieve, I'll do my best to help.
Is the above described condition possible to format? I have a similar need to where I would like a cell (L38) to change color when a different cell formatted as =Today() equals 12/1 of any given year. Meaning, I want the L38 cell to highlight yellow each year when today's date = 12/1. Additionally, I would like the highlight to stay active for seven days.
Hi,
I would like to add some formatting on cerain cells which contain dates. For example, I have a due date on colum A and a scheduled date on colum C. Now if the scheduled date is within 30 days of the due date, the scheduled date colum has to turn red.
I would also like to highlight column n to red if column c is populated with dates and those dates are within 30 days of column A.
Any help would be appreciated.
Thank you,
Hi Denis,
Select column N (from N2 and below) and create a conditional formatting rule using this formula:
=AND(C2<>"",A2-C2<30)
Then select column C and create another rule with the same formula.
I have a slightly different scenario than above. I have a date in column E and a date in column F. I need to highlight the date in column F if it is less than the date in column E.
Thanks for any help you can provide.
hello mijya excel help chaye agar ap help kar sakti ha to repli