MrExcel Message Board


Go Back   MrExcel Message Board > Question Forums > Excel Questions

Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only.

Reply
 
Thread Tools Display Modes
Old Mar 30th, 2004, 10:41 AM   #1
DebbieK
 
Join Date: Mar 2004
Posts: 2
Default Help needed in Conditional Formatting please

Hi

Can someone help me please, im pretty new to Excel and am having my first attempt at conditional formatting. I have created a spread sheet which has a column of dates.

I need the sheet to highlight todays date in red so I have:

=INT(G5)=TODAY()

I then need it to flag up dates in yellow up to 31 days ahead of todays date:

=AND(INT(G5)>TODAY(),(INT(G5)-TODAY())<31)

My problem is that I also need it to flag up dates prior to today, i.e. overdue dates in another colour. So what test do I need to put in for condition 3. Any help gratefully received
DebbieK is offline   Reply With Quote
Old Mar 30th, 2004, 11:12 AM   #2
fairwinds
MrExcel MVP
 
fairwinds's Avatar
 
Join Date: May 2003
Posts: 8,445
Default Re: Help needed in Conditional Formatting please

Welcome!

How about:

=INT(G5) < TODAY()
__________________
"Fair Winds and Following Seas"
fairwinds is offline   Reply With Quote
Old Mar 30th, 2004, 12:01 PM   #3
onlyadrafter
 
Join Date: Aug 2003
Location: England
Posts: 4,584
Default Re: Help needed in Conditional Formatting please

Hello and welcome to the board,

The three conditional formats you require are as follows:

CONDITION 1

Cell Value is equal to =TODAY()

CONDITION 2

Cell Value is less than = TODAY()

CONDITION 3

Cell Value is between =TODAY() =TODAY()+31

Select formats as required.

Use the format painter to format the other cells/column.

Is should be obvious into which INPUT BOXES the data goes in, any problems/queries let me know.
__________________
-------------------------
Hope this is helpful.
-------------------------
only a drafter,
but broadening my Excel knowledge.
onlyadrafter is offline   Reply With Quote
Old Mar 30th, 2004, 12:03 PM   #4
Whisperer14
 
Join Date: Nov 2002
Location: Cornwall UK
Posts: 589
Default

Debbie,

As Fairwind has shown, that will give you the answer you require and I offer the following formulae for you to experiment with. You can do it without formulae by using cell value. EDIT (as shown above)

If G5 is one of the dates in your column (formatted as a date format) that you wish to apply conditional formatting to then there is no need for the INT part of your formulae and they can be rewritten as shown below:
Code:
=G5
__________________
Never too old to learn...
Whisperer14 is offline   Reply With Quote
Old Mar 30th, 2004, 12:37 PM   #5
DebbieK
 
Join Date: Mar 2004
Posts: 2
Default Re: Help needed in Conditional Formatting please

Thank you all so much for your help I can stop tearing my hair out now Wish I had found these message boards before, they are great thanks again
DebbieK is offline   Reply With Quote
Old Mar 30th, 2004, 01:16 PM   #6
Aladin Akyurek
MrExcel MVP
 
Aladin Akyurek's Avatar
 
Join Date: Feb 2002
Location: The Hague
Posts: 39,332
Default Re: Help needed in Conditional Formatting please

Quote:
Originally Posted by DebbieK
Thank you all so much for your help I can stop tearing my hair out now Wish I had found these message boards before, they are great thanks again
I think G5 should at least be checked to house a number with each condition, otherwise the empty cells would satisfy some of your conditions and colored accordingly.
Aladin Akyurek is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT +1. The time now is 08:34 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
All contents Copyright 1998-2009 by MrExcel Consulting.