Sum range data in current month

adnandmth

New Member
Joined
Mar 25, 2019
Messages
3
How to sum range only data in current month?

for instance;

[TABLE="width: 300"]
<tbody>[TR]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[/TR]
[TR]
[TD]Jan[/TD]
[TD]Feb[/TD]
[TD]Mar[/TD]
[TD]Apr[/TD]
[TD]May[/TD]
[TD]Jun[/TD]
[TD]Jul[/TD]
[TD]Aug[/TD]
[TD]Sep[/TD]
[TD]Oct[/TD]
[TD]Nov[/TD]
[TD]Dec[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]0[/TD]
[TD]0[/TD]
[TD]2[/TD]
[TD]4[/TD]
[TD]5[/TD]
[TD]0[/TD]
[TD]0[/TD]
[TD]8[/TD]
[TD]9[/TD]
[TD]0[/TD]
[TD]2[/TD]
[/TR]
</tbody>[/TABLE]


I want dynamically sum the range A:L but the result should only count from first (A) to the current month (Aug), how do I achieve this goal?
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Hi, here is one option:


Excel 2013/2016
ABCDEFGHIJKLMN
1JanFebMarAprMayJunJulAugSepOctNovDecSum
210024500890212
Sheet1
Cell Formulas
RangeFormula
N2=SUM(A2:INDEX(A2:L2,MONTH(TODAY())))
 
Upvote 0
Hi FormR, thanks for the quick reply,


[TABLE="class: outer_border, width: 300"]
<tbody>[TR]
[TD]A[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD][/TD]
[TD]Sum[/TD]
[/TR]
[TR]
[TD][/TD]
[TD]Jan[/TD]
[TD]Feb[/TD]
[TD]Mar[/TD]
[TD]Apr[/TD]
[TD]May[/TD]
[TD]Jun[/TD]
[TD]Jul[/TD]
[TD]Aug[/TD]
[TD]Sep[/TD]
[TD]Oct[/TD]
[TD]Nov[/TD]
[TD]Dec[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Joined Date[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]20/02/2019
[/TD]
[TD]1[/TD]
[TD]0[/TD]
[TD]2[/TD]
[TD]3[/TD]
[TD]5[/TD]
[TD]0[/TD]
[TD]0[/TD]
[TD]8[/TD]
[TD]7[/TD]
[TD]2[/TD]
[TD]2[/TD]
[TD]2[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

Actually I have another problems in my case;
1. the sum function should start from the month where the person was joined +1, I mean if a person joined in feb then starts from march and so on
2. and the range should stop in the current month -1, current month is august then range should be between March and Jul

Could you help me to achieve this goal??
[TABLE="width: 85%"]
<tbody></tbody>[/TABLE]
 
Upvote 0
Hi, something like this maybe:


Excel 2013/2016
ABCDEFGHIJKLMNO
1Joined DateJanFebMarAprMayJunJulAugSepOctNovDecSum
220/02/201910235008722210
Sheet1
Cell Formulas
RangeFormula
O2=SUM(INDEX(B2:M2,MONTH(A2)):INDEX(B2:M2,MONTH(TODAY())-1))
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

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
Back
Top