+ Reply to Thread
Results 1 to 3 of 3

sum using year and between months

  1. #1
    Registered User
    Join Date
    10-03-2015
    Location
    west coast is the best coast
    MS-Off Ver
    excel 2010
    Posts
    113

    sum using year and between months

    Hello. I have data across three years. I have three cells. Years and start month/end month. How can I write a formula that will sum based on this criteria? Spreadsheet attached. Thanks!!
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    12-03-2009
    Location
    Florence, Italy
    MS-Off Ver
    Excel 2019
    Posts
    1,796

    Re: sum using year and between months

    Hi,

    =SUMPRODUCT(A3:AJ3,(YEAR(A2:AJ2)=AL1)*(MONTH(A2:AJ2)>=MONTH(AL2&1))*(MONTH(A2:AJ2)<=MONTH(AM2&1)))

    if you could write 1 instead of January and 4 insead of April:

    =SUMPRODUCT(A3:AJ3,(YEAR(A2:AJ2)=AL1)*(MONTH(A2:AJ2)>=AL2)*(MONTH(A2:AJ2)<=AM2))

    Hope it helps
    -----------------------------------------------------

    At Excelforum, you can say "Thank you!" by clicking the star icon ("Add Reputation") below the post.

    Please, mark your thread [SOLVED] if you received your answer.

  3. #3
    Registered User
    Join Date
    10-03-2015
    Location
    west coast is the best coast
    MS-Off Ver
    excel 2010
    Posts
    113

    Re: sum using year and between months

    @ canapone. That worked!! Thanks

+ 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] VBA Insert Current Month, Year and subsequent months/year for 15 months
    By MichiganWilliams in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-19-2014, 03:49 PM
  2. [SOLVED] Months of the year
    By Sammitry in forum Excel General
    Replies: 3
    Last Post: 05-09-2012, 05:53 AM
  3. Months of the year
    By britt@wjg in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-02-2010, 01:38 PM
  4. Replies: 3
    Last Post: 03-12-2009, 09:54 AM
  5. [SOLVED] Combined Months of a year into a year
    By Djchaney3 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-12-2007, 09:41 AM
  6. [SOLVED] Within 6 months, Within 1 year and so on...
    By MER in forum Excel General
    Replies: 1
    Last Post: 08-02-2006, 03:10 PM
  7. [SOLVED] How do i change 15 months to read 1 year and 3 months?
    By Marty in forum Excel General
    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