+ Reply to Thread
Results 1 to 10 of 10

Find date in another sheet and sum 12 cells

  1. #1
    Registered User
    Join Date
    11-27-2020
    Location
    Denmark
    MS-Off Ver
    Office365
    Posts
    13

    Find date in another sheet and sum 12 cells

    Hi guys,

    I love this place, I always get good and useful feedback on issues and ideas.

    Now, I have a new issue that I can't find the correct solution for.

    In my overview I have this formula:

    =VLOOKUP($C$4;INDIRECT("'"&A5&"'!B24:D119");3;FALSE)

    That works like a charm and shows me the correct number.

    Now, I would also like to sum up 12 cells (interests for the 12 months (including the current month) to be summed in my overview).

    Is it possible?

    My setup is like this: "Overview"-sheet contains name of alle sheets and a formula to extract the current debt based on a date i submit to the sheet - e.g. 31.12.2020.
    Is it possible to tell Excel to find this date, and "autosum" this date and the last 11 cells so I have 12 months interest?

    Please see attached file which is the actual file per agreement. The yellow fields I would like to sum when selecting the date 01.07.2017 in my overview.

    * Updated with new Excel file *
    Attached Files Attached Files
    Last edited by burgiz; 02-04-2021 at 09:13 AM.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2406 (Windows 11 23H2 64-bit)
    Posts
    82,705

    Re: Find date in another sheet and sum 12 cells

    Where is the overview sheet containing your formula? I see only one sheet here.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Find date in another sheet and sum 12 cells

    I can't see an Overview sheet in your sample file, but basically you can use a SUM function which contains INDEX/MATCH functions which define the range you want to sum.

    Hope this helps.

    Pete

  4. #4
    Registered User
    Join Date
    11-27-2020
    Location
    Denmark
    MS-Off Ver
    Office365
    Posts
    13

    Re: Find date in another sheet and sum 12 cells

    Sorry for the inconvenience, I have just added the correct file.
    Attached Files Attached Files
    Last edited by burgiz; 02-04-2021 at 05:32 AM.

  5. #5
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Find date in another sheet and sum 12 cells

    Isn't that the same file?

    Pete

  6. #6
    Registered User
    Join Date
    11-27-2020
    Location
    Denmark
    MS-Off Ver
    Office365
    Posts
    13

    Re: Find date in another sheet and sum 12 cells

    Quote Originally Posted by Pete_UK View Post
    Isn't that the same file?

    Pete
    You are right, but now the files should be correct - I'm sorry :-)

  7. #7
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Find date in another sheet and sum 12 cells

    You can use this formula in E3:

    =SUM(INDEX(INDIRECT("'"&A3&"'!F:F");MATCH($D$1;INDIRECT("'"&A3&"'!B:B");0)):INDEX(INDIRECT("'"&A3&"'!F:F");MATCH($D$1;INDIRECT("'"&A3&"'!B:B");0)-11))

    to sum 12 cells from column F in the sheet whose name is in A3.

    Hope this helps.

    Pete

  8. #8
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,427

    Re: Find date in another sheet and sum 12 cells

    On an aside, I wouldn't use whole column references within an INDIRECT. It can get very slow on big sheets with lots of formulae.
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  9. #9
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,852

    Re: Find date in another sheet and sum 12 cells

    Hi Glenn,

    I agree, but the OP used this range in the first post B24:D119, but that wouldn't have worked with the sample file which only had data up to row 19, so I figured if I put in full column ranges then the OP could adjust those quite easily to suit the real data. I suppose I should have pointed that out, so thanks.

    Pete

  10. #10
    Registered User
    Join Date
    11-27-2020
    Location
    Denmark
    MS-Off Ver
    Office365
    Posts
    13

    Re: Find date in another sheet and sum 12 cells

    Hi guys, and especially you Pete_UK, thank you very much for your answer! It did the job just perfect - thank you :-)

+ 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. Copy cell from one sheet, find coresponding date on 2nd sheet data table, paste value
    By Soccer0228 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-08-2019, 01:14 PM
  2. [SOLVED] find date that matches date on my sheet and copy from table below.
    By k1989l in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-07-2016, 08:02 AM
  3. Replies: 1
    Last Post: 07-20-2015, 09:22 PM
  4. Macro to find Date Cells > Current Date and delete everything to left of that cell
    By LewisLonsdale in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-25-2015, 06:36 AM
  5. [SOLVED] Cells.Find xlDate does not find first date in sheet unless date format is dd/mm/yyyy
    By AtTheControls in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 11-07-2013, 12:35 PM
  6. Find a date value in a sheet and delete all cells to the right of it in the row
    By pajc72 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-25-2013, 11:05 AM
  7. [SOLVED] Find the date and copy the values from the colum of the date find and paste to other sheet
    By nizzcmzph in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 02-20-2013, 10:03 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