+ Reply to Thread
Results 1 to 4 of 4

Thread: Summing if value is a weekend

  1. #1
    Registered User
    Join Date
    01-09-2012
    Location
    Modesto, CA
    MS-Off Ver
    Excel 2007
    Posts
    9

    Summing if value is a weekend

    Hello,

    I need to sum only the cells in a column if the date in another column is a weekend. I thought that =SUMIF(A5:A35,WEEKDAY(A5:A35,2)>5,X5:X35) would do the trick but it returns zero.

    John
    Last edited by John007; 01-10-2012 at 11:21 AM.

  2. #2
    Cheeky Forum Moderator Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2003, 2007, 2010
    Posts
    3,711

    Re: Summing if value is a weekend

    Try this regular formula
    =SUMPRODUCT((WEEKDAY(A5:A35,2)>5)*X5:X35)
    Does that help?
    Regards,

    Ron
    Microsoft MVP - Excel
    (Oct 2006 - Sep 2012)

    Click here to see the Forum Rules

  3. #3
    Registered User
    Join Date
    01-09-2012
    Location
    Modesto, CA
    MS-Off Ver
    Excel 2007
    Posts
    9

    Re: Summing if value is a weekend

    Wow, I love this place! That does the trick. Spent a couple hours on that and in a matter of moments I get a solution. As always, once you see the solution, you ask, "Why didn't I see that?" Thanks!!!

  4. #4
    Cheeky Forum Moderator Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2003, 2007, 2010
    Posts
    3,711

    Re: Summing if value is a weekend

    You're welcome...Glad I could help.
    Regards,

    Ron
    Microsoft MVP - Excel
    (Oct 2006 - Sep 2012)

    Click here to see the Forum Rules

+ 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.2.0