+ Reply to Thread
Results 1 to 6 of 6

Change cell color according to date

  1. #1
    Registered User
    Join Date
    08-08-2013
    Location
    Massachusetts
    MS-Off Ver
    Excel 2007
    Posts
    4

    Change cell color according to date

    I read the following instructions in this thread:
    http://www.excelforum.com/excel-form...-new-post.html

    but am running into a problem where cells without a value (entered date) are turning to red or yellow etc. If there is no value, I'd like the cells to remain white. Can you help me with a formula which will do this?

    I want cells to turn to red if the date is greater than or equal to 14 days prior to today's date.

    I am currently using Excel 2007 and Conditional Formatting with the following rule:

    =$D2:I500<TODAY()-14

    I'm new to the programming language so appreciate any explanation and advice. Thank you.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,448

    Re: Change cell color according to date

    Select your range ( say $D$2:$i$500) and enter following CF =and(D2<>"",D2>=today()-14)
    Format red as needed

  3. #3
    Forum Contributor rajeshturaha's Avatar
    Join Date
    08-22-2012
    Location
    Assam, India
    MS-Off Ver
    Excel 2003, 2007
    Posts
    236

    Re: Change cell color according to date

    I think this will solve your problem
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    in CF in D2
    Rgd
    RT
    If my answer(s) helped you, please add me reputation by click on *

  4. #4
    Registered User
    Join Date
    08-08-2013
    Location
    Massachusetts
    MS-Off Ver
    Excel 2007
    Posts
    4

    Re: Change cell color according to date

    Thank you both. I've tried both formulas and neither is working. I'm still getting red in cells where there is not a value and I'm also getting them where the date is further out than today's date.
    Any other suggestions for me to try?

  5. #5
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,448

    Re: Change cell color according to date

    See attached
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    08-08-2013
    Location
    Massachusetts
    MS-Off Ver
    Excel 2007
    Posts
    4

    Re: Change cell color according to date

    Thank you. I misunderstood the previous posts. I understand now.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Change Cell Color According To Date
    By msisk83 in forum Excel Formulas & Functions
    Replies: 16
    Last Post: 08-08-2013, 09:47 AM
  2. Macro to Change color of cell after cross referencing date with a given date.
    By liajet24 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-24-2013, 12:33 PM
  3. [SOLVED] change background row color with change of date in a cell
    By Urszula in forum Excel General
    Replies: 5
    Last Post: 05-17-2006, 03:00 AM
  4. cell color change based on due date
    By MINAL ZUNKE in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 06-30-2005, 05:05 PM
  5. [SOLVED] Change cell color dependin on date ...
    By T. Denford in forum Excel General
    Replies: 16
    Last Post: 04-13-2005, 06:06 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1