+ Reply to Thread
Results 1 to 12 of 12

Conditional formatting to highlights duplicate date from yesterdays date

  1. #1
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Conditional formatting to highlights duplicate date from yesterdays date

    I wanted to highlight all the data from yesterdays date

    When I use this, same date has been highlighted
    =IF(COUNTIFS($F:$F,$F1,$G:$G,$G1,$H:$H,$H1)>1, TRUE,FALSE)

    Date Number Color
    4/17/2024 1 Blue
    4/17/2024 2 Yellow
    4/17/2024 3 Red
    4/17/2024 4 Violet
    4/17/2024 5 Blue
    4/17/2024 6 Yellow
    4/17/2024 7 Red
    4/17/2024 8 Violet
    4/17/2024 9 Blue
    4/18/2024 6 Yellow
    4/17/2024 11 Red
    4/17/2024 12 Violet
    4/17/2024 13 Blue
    4/17/2024 14 Yellow
    4/17/2024 15 Red
    4/17/2024 16 Violet
    4/18/2024 17 Blue
    4/19/2024 17 Blue
    4/19/2024 19 Red
    4/19/2024 20 Violet
    4/21/2024 21 Blue

    These will be the highlighted. Everyday new date and data will be added in the file.
    4/17/2024 6 Yellow
    4/18/2024 6 Yellow

    4/18/2024 17 Blue
    4/19/2024 17 Blue
    Attached Files Attached Files
    Last edited by dummy777; 04-18-2024 at 09:20 AM.

  2. #2
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.84 (24041420))
    Posts
    8,751

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    in conditional formatting you only need to use
    COUNTIFS($F:$F,$F1,$G:$G,$G1,$H:$H,$H1)>1
    however
    note sure what the issue is / question

    if the date is in column F - no idea if it is , just guessing , then different dates will not be highlighted
    $F:$F,$F1,
    as this is only looking for the same date

    Please see the Yellow Banner at the top of the page explaining how to attach a sample spreadsheet

    A good sample workbook has just 10-20 rows of representative data that has been desensitised. The sample layout accurately matches that of your real data. It also has expected results mocked up, worked examples where required, relevant cells highlighted and a few explanatory notes.


    Here are the instructions, found at the top of the page again
    HOW TO ATTACH YOUR SAMPLE WORKBOOK:, Fast answers need clear examples. Post a small Excel sheet (not a picture) showing realistic & representative sample data WITHOUT confidential information (10-20 rows, not thousands...) and some manually calculated results. For a new thread (1st post), scroll to Manage Attachments, otherwise scroll down to GO ADVANCED, click, and then scroll down to MANAGE ATTACHMENTS and click again. Now follow the instructions at the top of that screen.
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    This is my sample attachment. I want the 4/17 & 4/18, 6, yellow to be highlighted. As well as the 4/18 & 4/19, 17, blue. As long as the number duplicates. Data or row should be highlighted because it is a duplicate of yesterdays data.

    Example. If there is a data on 4/17 & 4/19, it will not be highlighted.. but if the duplicate is on 4/17 & 4/18, both will be highlighted.. so on and so forth..
    Attached Files Attached Files
    Last edited by dummy777; 04-18-2024 at 09:20 AM.

  4. #4
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,459

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Please try this CF-rule =COUNTIF($G:$G,$G2)>1 applies to $F$2:$H$999
    Attached Files Attached Files

  5. #5
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Quote Originally Posted by HansDouwe View Post
    Please try this CF-rule =COUNTIF($G:$G,$G2)>1 applies to $F$2:$H$999
    Thank you but it highlights even if there is a duplicate in 4/17 & 4/19. Is it possible if it highlights the yesterdays and todays working dates?

  6. #6
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,459

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Quote Originally Posted by dummy777 View Post
    I want the 4/17 & 4/18, 6, yellow to be highlighted. As well as the 4/18 & 4/19, 17, blue. As long as the number duplicates.
    ....
    Is it possible if it highlights the yesterdays and todays working dates?
    I don't understand what you mean, because 4/19 is not today or yesterday, but it should be highlighted??

    And now you also introduce the term working date. What do you mean with that?

  7. #7
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Quote Originally Posted by HansDouwe View Post
    I don't understand what you mean, because 4/19 is not today or yesterday, but it should be highlighted??

    And now you also introduce the term working date. What do you mean with that?
    I mean, if the duplicate data is from 4/16 & 4/18, it should NOT be highlighted. But if the duplicate data is from 4/17 & 4/18, both will be highligted.. dates were from yesterdays and todays data.. then tomorrow if the dup date is in 4/17 & 4/19, it will NOt highlight.. but if the dates were 4/18 & 4/19, those 2 data will be highlighted. Sorry if it was confusing.

    Then, when weekends.. dup data from fri and monday should be highlighted.

  8. #8
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,459

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Because you are talking about today and yesterday, I have more questions?

    Do you want to highlight 4/17 & 4/18 with a duplicate number only when it is 4/18?
    Do you want to highlight 4/18 & 4/19 with a duplicate number only when it is 4/19?

  9. #9
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Quote Originally Posted by HansDouwe View Post
    Because you are talking about today and yesterday, I have more questions?

    Do you want to highlight 4/17 & 4/18 with a duplicate number only when it is 4/18?
    Do you want to highlight 4/18 & 4/19 with a duplicate number only when it is 4/19?
    Yes that is correct.

  10. #10
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,459

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Please try this CF-rule applies to $F$2:$H$999:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files

  11. #11
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    Quote Originally Posted by HansDouwe View Post
    Please try this CF-rule applies to $F$2:$H$999:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Thank you so much!

  12. #12
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,459

    Re: Conditional formatting to highlights duplicate date from yesterdays date

    You are Welcome!

    Thanks for the feedback and rep.

    Glad to have helped .

+ 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. Replies: 13
    Last Post: 10-15-2022, 12:51 AM
  2. [SOLVED] Conditional Formatting highlights none duplicate based on rows & columns
    By chaiyya345 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 03-01-2021, 04:52 AM
  3. [SOLVED] look to see if yesterdays date or todays date is in worksheet
    By JRJLHJ1823 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-21-2015, 10:15 PM
  4. [SOLVED] VBA to loop through and delete all date except Yesterdays date.
    By shiva_reshs in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 07-09-2014, 11:30 AM
  5. [SOLVED] Conditional formatting: Cell highlights after a given date
    By peoplemover in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-09-2013, 06:49 PM
  6. [SOLVED] Function/formula to compare and insert todays date or yesterdays date
    By TC922 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-17-2013, 05:28 AM
  7. How can I get yesterdays date in a custom footer &[DATE]-1 does .
    By chuck in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-18-2005, 10: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