Calculate MTD with Sumif SumProduct Indirect

leighnea

New Member
Joined
Jul 25, 2009
Messages
18
=SUMPRODUCT(SUMIF(INDIRECT("'"&list&"'!d2:d100"),D11,INDIRECT("'"&list&"'!e2:e100")))


This is the formula I used and this adds all 31 tabs however I need to sum only based on what day the report is being ran for.
 

Some videos you may like

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.

Domenic

MrExcel MVP
Joined
Mar 10, 2004
Messages
19,406
How are the sheets named? If, for example, the sheets are named 1, 2, 3, etc., try...

=SUMPRODUCT(SUMIF(INDIRECT("'"&ROW(INDIRECT("1:"&DAY(TODAY())))&"'!D2:D100"),D11,INDIRECT("'"&ROW(INDIRECT("1:"&DAY(TODAY())))&"'!E2:E100")))

If the sheets are named Sep 1, Sep 2, Sep 3, etc., replace...

ROW(INDIRECT("1:"&DAY(TODAY())))

with

TEXT(DATE(YEAR(TODAY()),MONTH(TODAY()),ROW(INDIRECT("1:"&DAY(TODAY())))),"mmm d")

If the sheets are named 09/01/14, 09/02/14, 09/03/14, etc., replace...

ROW(INDIRECT("1:"&DAY(TODAY())))

with

TEXT(DATE(YEAR(TODAY()),MONTH(TODAY()),ROW(INDIRECT("1:"&DAY(TODAY())))),"mm/dd/yy")

Hope this helps!
 

Watch MrExcel Video

Forum statistics

Threads
1,122,469
Messages
5,596,316
Members
414,053
Latest member
Dual Showman

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top