+ Reply to Thread
Results 1 to 5 of 5

Color cell by date

  1. #1
    Registered User
    Join Date
    01-21-2022
    Location
    France
    MS-Off Ver
    Office 2019
    Posts
    2

    Color cell by date

    Hello,

    I need to generate an attendance sheet and I have several Excel sheets, one which contains the attendance table and another which contains cells where you can add the departure date and the return date of an employee with a reason, the concern is that I can't get the departure date and the date just before the return as well as the days in between to be colored red with the reason written in the cell colored red.

    The cells that will not be colored in the table should automatically be colored green.
    Would it be possible to help me?
    I have attached the file

    Thank you.
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,548

    Re: Color cell by date

    Hello Tikserz and Welcome to Excel Forum.
    This proposal changes the arrangement on the Absences sheet as modeled in columns D:F.
    The conditional formatting rule is: =COUNTIFS(Absences!D$2:D$3,"<="&B9,Absences!E$2:E$3,">="&B9)
    The formula to put the reason in the cells is:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Question: Do you want all other cells colored green or do you still want weekends colored gray?
    Let us know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  3. #3
    Registered User
    Join Date
    01-21-2022
    Location
    France
    MS-Off Ver
    Office 2019
    Posts
    2

    Re: Color cell by date

    Hello,
    Well that's all good so I managed to do the rest, thank you very much. My problem was mainly the absences

  4. #4
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,548

    Re: Color cell by date

    You're Welcome and thank you for the feedback. Please take a moment to mark the thread as 'Solved' using the thread tools menu above your first post. I hope that you have a blessed day.

  5. #5
    Registered User
    Join Date
    01-24-2022
    Location
    australia
    MS-Off Ver
    365
    Posts
    7

    Re: Color cell by date

    thanks this helped me out as well

+ 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. AutoSort by cell color and ole date to new date
    By indhrui in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-15-2020, 07:46 PM
  2. Replies: 3
    Last Post: 01-02-2018, 08:15 PM
  3. Replies: 2
    Last Post: 04-22-2015, 03:42 PM
  4. [SOLVED] VBA Macro to Color Row Text If Date in Cell is greater than system date
    By slick9456 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-24-2014, 06:09 PM
  5. 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
  6. Replies: 2
    Last Post: 06-18-2013, 01:21 PM
  7. Color fill a cell and then remove the color when a date is added.
    By texas tornado in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-25-2012, 02:14 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