+ Reply to Thread
Results 1 to 6 of 6

check date to see if it's weekend, conditional formatting

  1. #1
    Registered User
    Join Date
    09-20-2009
    Location
    Netherlands
    MS-Off Ver
    Excel 2007
    Posts
    18

    Question check date to see if it's weekend, conditional formatting

    Hello everyone,

    I would like to use a conditional formatting formula which indicates whether a date is a weekend day, is this possible? To make it extra challeging (/annoying), it has to be in one line, because I can only use 3 conditions (openoffice calc) and am already using 2.

    Thanks in advance!!

    Best,
    DMR1712

  2. #2
    Registered User
    Join Date
    03-16-2009
    Location
    London, UK
    MS-Off Ver
    Excel 16.78 on Mac - Office 365.
    Posts
    80

    Re: check date to see if it's weekend, conditional formatting

    If your date is in A1 then use this formula for your conditional formatting rule:

    =(WEEKDAY(A1)-6)>=0

  3. #3
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: check date to see if it's weekend, conditional formatting

    deemo, not quite.

    Weekday() returns 7 for a Saturday and 1 for a Sunday, unless used with the second parameter. Without this parameter the statement for conditional formatting needs to be

    =OR(WEEKDAY(A1)=1,WEEKDAY(A1)=7)

  4. #4
    Registered User
    Join Date
    03-16-2009
    Location
    London, UK
    MS-Off Ver
    Excel 16.78 on Mac - Office 365.
    Posts
    80

    Re: check date to see if it's weekend, conditional formatting

    Ouch! Sorry about that... (red faced)

  5. #5
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: check date to see if it's weekend, conditional formatting

    For sake of OP perhaps simplest to use:

    =WEEKDAY(A1;2)>5

  6. #6
    Registered User
    Join Date
    09-20-2009
    Location
    Netherlands
    MS-Off Ver
    Excel 2007
    Posts
    18

    [SOLVED] Re: check date to see if it's weekend, conditional formatting

    I used the last one, works like a charm!

    thanks for your help.

    best regards,
    DMR1712

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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