+ Reply to Thread
Results 1 to 4 of 4

How do I highlight cells that do not contain valid dates.

  1. #1
    Registered User
    Join Date
    05-20-2013
    Location
    Kegworth, England
    MS-Off Ver
    Excel 2019
    Posts
    58

    How do I highlight cells that do not contain valid dates.

    Hi All,
    I have a series of sheets contain dates of when employee training is either planned (blue), current (green), within 2 months of being out of date (amber) or out of date (red).
    I use the formula function within conditional formatting to colour the relevant cells, relative to the date entered in them.
    For example, to display cells shaded blue to show that training is planned I use the formula "=AND(C6<>"",C6>TODAY().
    I then have this formula applied to cells to $C$6:$M$48 and this all works perfectly well.

    What I would like to know is; Is there a way, using a conditional formatting formula, to highlight cells when anything is entered into the cells that is not a valid date?

    Regards

    Drew

  2. #2
    Forum Contributor Obsessed's Avatar
    Join Date
    05-22-2013
    Location
    Cincinnati, Ohio
    MS-Off Ver
    Excel 365
    Posts
    215

    Re: How do I highlight cells that do not contain valid dates.

    I'd just use data validation to force a date to be entered.
    Want to show appreciation for the help you received from a member? Give them reps by clicking the bottom left of their post!

  3. #3
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,998

    Re: How do I highlight cells that do not contain valid dates.

    This returns TRUE if a cell contains a valid date:

    =AND(ISNUMBER(A1),LEFT(CELL("format",A1),1)="D")

    so, you could try this:

    =NOT(AND(ISNUMBER(A1),LEFT(CELL("format",A1),1)="D"))
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  4. #4
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: How do I highlight cells that do not contain valid dates.

    =$a1=text($a1,"ddd")

+ 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. [SOLVED] Highlight cells between two dates
    By YasserKhalil in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-25-2015, 05:05 AM
  2. [SOLVED] Help with Macro to highlight cells between dates
    By Slomaro2000 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-27-2015, 03:29 PM
  3. [SOLVED] Highlight Cells Based on Dates
    By pugsly8422 in forum Excel General
    Replies: 3
    Last Post: 01-27-2015, 01:09 PM
  4. [SOLVED] Trying to get Excel to highlight cells based on assigned dates.
    By tatumrae in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 04-10-2013, 08:25 PM
  5. Highlight item not in Valid List
    By smalltime in forum Excel General
    Replies: 2
    Last Post: 09-24-2009, 10:01 PM
  6. [SOLVED] counting valid dates in a range of cells
    By TBA in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 06-28-2006, 11:45 PM
  7. automatically highlight cells with expired dates?!
    By cwest123456 in forum Excel General
    Replies: 2
    Last Post: 08-01-2005, 02:05 PM

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