Sum a column until a specific number is reached

DocDeb

New Member
Joined
Jan 15, 2008
Messages
31
Office Version
  1. 365
Platform
  1. Windows
I would like to Sum a column until 50 is reached. Continue summing the same column again with the remainder from the previous cell if over 50 until 50 is reached again and keep going.
In an adjacent column insert consecutive numbers for each sum of 50.
 
I don't know if i got it right. Isn't the result you need the vol column?

If so, would this work? Just check column E (vol) (the others are just quick helper column to get to that result which can be compacted into a one cell formula)


Book1
ABCDE
1SizeSumMod 50AuxVol
2
3505001Vol 1
425220 
54910111Vol 2
610220332Vol 3 to 4
745.6248.648.60 
8150398.648.63Vol 5 to 7
945443.643.61Vol 8
1015458.68.61Vol 9
Sheet1 (2)
Cell Formulas
RangeFormula
B3:B10B3=SUM($A$3:A3)
C3:C10C3=MOD(SUM($A$3:A3), 50)
D3D3=(B3-C3)/50
E3:E10E3=IF(D3, "Vol "&SUM($D$2:D2) + 1 & IF(D3>1, " to "&SUM($D$2:D2)+D3, ""), "")
D4:D10D4=(B4-C4)/50-SUM($D$3:D3)
This looked really cool! I like the Vols being displayed as combined
Thank you.
Although, this is still not totally there. :(

0.50.50.5 (Good)
5555.55.5 (Good)
101106.556.5 (Good)
7581.531.5 (This should be 81.5)

But, in Column C, I think I will just use =IF(B2-50<0,B2,B2-50) I wanted a more dynamic calculation, but this should do since Column B is working (as far as I can tell).
Seriously! What an idiot I am for not seeing what you did was correct!
 
Upvote 0

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
I don't know if i got it right. Isn't the result you need the vol column?

If so, would this work? Just check column E (vol) (the others are just quick helper column to get to that result which can be compacted into a one cell formula)


Book1
ABCDE
1SizeSumMod 50AuxVol
2
3505001Vol 1
425220 
54910111Vol 2
610220332Vol 3 to 4
745.6248.648.60 
8150398.648.63Vol 5 to 7
945443.643.61Vol 8
1015458.68.61Vol 9
Sheet1 (2)
Cell Formulas
RangeFormula
B3:B10B3=SUM($A$3:A3)
C3:C10C3=MOD(SUM($A$3:A3), 50)
D3D3=(B3-C3)/50
E3:E10E3=IF(D3, "Vol "&SUM($D$2:D2) + 1 & IF(D3>1, " to "&SUM($D$2:D2)+D3, ""), "")
D4:D10D4=(B4-C4)/50-SUM($D$3:D3)
I was looking for a bit of help with counting the Vols, and I see where you are going with this solution.
Column B doesn't start over after 50 but is use to count the Vols in Column D with Vols displayed in Column E. I like the Vols being displayed as combined e.g."Vol 3 to 4".
 
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,239
Members
452,621
Latest member
Laura_PinksBTHFT

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