Split payment based on date

JDJong

New Member
Joined
May 2, 2018
Messages
39
Hey all,

I am having trouble to come up with a formula to auto-populate the split amount based on the starting period (Column A) and ending period (Column B)

I have been able to split the amount with formula, however, I would like to Transfer them to the respective periods in column H - column V based on the period that they fall into.

Could you guys help me to come up with a formula to Auto-populate the sheet?

Many thanks in advance~!
A B C E F
[TABLE="width: 535"]
<colgroup><col><col><col><col><col span="2"></colgroup><tbody>[TR]
[TD]Period Start[/TD]
[TD]Period End[/TD]
[TD]Amount[/TD]
[TD][/TD]
[TD]1st period[/TD]
[TD]2nd period[/TD]
[/TR]
[TR]
[TD="align: right"]10/12/2017[/TD]
[TD="align: right"]09/01/2018[/TD]
[TD] 70.525,00[/TD]
[TD][/TD]
[TD="align: right"]49367,50[/TD]
[TD="align: right"]21157,50[/TD]
[/TR]
[TR]
[TD="align: right"]11/12/2017[/TD]
[TD="align: right"]10/01/2018[/TD]
[TD] 30.000,00[/TD]
[TD][/TD]
[TD="align: right"]20000,00[/TD]
[TD="align: right"]10000,00[/TD]
[/TR]
[TR]
[TD="align: right"]21/11/2017[/TD]
[TD="align: right"]20/12/2017[/TD]
[TD] 57.000,00[/TD]
[TD][/TD]
[TD="align: right"]17689,66[/TD]
[TD="align: right"]39310,34[/TD]
[/TR]
[TR]
[TD="align: right"]26/12/2017[/TD]
[TD="align: right"]25/01/2018[/TD]
[TD]241.800,00[/TD]
[TD][/TD]
[TD="align: right"]40300,00[/TD]
[TD="align: right"]201500,00[/TD]
[/TR]
[TR]
[TD="align: right"]17/12/2017[/TD]
[TD="align: right"]16/01/2018[/TD]
[TD] 89.900,00[/TD]
[TD][/TD]
[TD="align: right"]41953,33[/TD]
[TD="align: right"]47946,67[/TD]
[/TR]
[TR]
[TD="align: right"]30/12/2017[/TD]
[TD="align: right"]29/01/2018[/TD]
[TD] 69.750,00[/TD]
[TD][/TD]
[TD="align: right"]2325,00[/TD]
[TD="align: right"]67425,00[/TD]
[/TR]
[TR]
[TD="align: right"]29/12/2017[/TD]
[TD="align: right"]28/01/2018[/TD]
[TD] 71.300,00[/TD]
[TD][/TD]
[TD="align: right"]4753,33[/TD]
[TD="align: right"]66546,67[/TD]
[/TR]
[TR]
[TD="align: right"]03/01/2018[/TD]
[TD="align: right"]02/02/2018[/TD]
[TD] 60.140,00[/TD]
[TD][/TD]
[TD="align: right"]56130,67[/TD]
[TD="align: right"]4009,33[/TD]
[/TR]
[TR]
[TD="align: right"]08/12/2017[/TD]
[TD="align: right"]07/01/2018[/TD]
[TD] 58.280,00[/TD]
[TD][/TD]
[TD="align: right"]44681,33[/TD]
[TD="align: right"]13598,67[/TD]
[/TR]
[TR]
[TD="align: right"]09/12/2017[/TD]
[TD="align: right"]08/01/2018[/TD]
[TD] 62.000,00[/TD]
[TD][/TD]
[TD="align: right"]45466,67[/TD]
[TD="align: right"]16533,33[/TD]
[/TR]
[TR]
[TD="align: right"]09/12/2017[/TD]
[TD="align: right"]08/01/2018[/TD]
[TD] 69.750,00[/TD]
[TD][/TD]
[TD="align: right"]51150,00[/TD]
[TD="align: right"]18600,00[/TD]
[/TR]
[TR]
[TD="align: right"]07/12/2017[/TD]
[TD="align: right"]06/01/2018[/TD]
[TD] 65.100,00[/TD]
[TD][/TD]
[TD="align: right"]52080,00[/TD]
[TD="align: right"]13020,00[/TD]
[/TR]
[TR]
[TD="align: right"]23/12/2017[/TD]
[TD="align: right"]22/01/2018[/TD]
[TD] 40.145,00[/TD]
[TD][/TD]
[TD="align: right"]10705,33[/TD]
[TD="align: right"]29439,67[/TD]
[/TR]
[TR]
[TD="align: right"]07/12/2017[/TD]
[TD="align: right"]06/01/2018[/TD]
[TD] 52.000,00[/TD]
[TD][/TD]
[TD="align: right"]41600,00[/TD]
[TD="align: right"]10400,00[/TD]
[/TR]
[TR]
[TD="align: right"]24/12/2017[/TD]
[TD="align: right"]23/01/2018[/TD]
[TD] 50.187,22[/TD]
[TD][/TD]
[TD="align: right"]11710,35[/TD]
[TD="align: right"]38476,87[/TD]
[/TR]
[TR]
[TD="align: right"]23/12/2017[/TD]
[TD="align: right"]22/01/2018[/TD]
[TD] 42.375,37[/TD]
[TD][/TD]
[TD="align: right"]11300,10[/TD]
[TD="align: right"]31075,27[/TD]
[/TR]
[TR]
[TD="align: right"]09/12/2017[/TD]
[TD="align: right"]08/01/2018[/TD]
[TD] 9.401,00[/TD]
[TD][/TD]
[TD="align: right"]6894,07[/TD]
[TD="align: right"]2506,93[/TD]
[/TR]
[TR]
[TD="align: right"]14/12/2017[/TD]
[TD="align: right"]13/01/2018[/TD]
[TD] 35.852,06[/TD]
[TD][/TD]
[TD="align: right"]20316,17[/TD]
[TD="align: right"]15535,89[/TD]
[/TR]
[TR]
[TD="align: right"]23/12/2017[/TD]
[TD="align: right"]22/01/2018[/TD]
[TD] 31.000,00[/TD]
[TD][/TD]
[TD="align: right"]8266,67[/TD]
[TD="align: right"]22733,33[/TD]
[/TR]
[TR]
[TD="align: right"]01/12/2017[/TD]
[TD="align: right"]31/12/2017[/TD]
[TD] 68.200,00[/TD]
[TD][/TD]
[TD="align: right"]0,00[/TD]
[TD="align: right"]70473,33[/TD]
[/TR]
[TR]
[TD="align: right"]11/12/2017[/TD]
[TD="align: right"]10/01/2018[/TD]
[TD] 56.265,00[/TD]
[TD][/TD]
[TD="align: right"]37510,00[/TD]
[TD="align: right"]18755,00[/TD]
[/TR]
[TR]
[TD="align: right"]20/12/2017[/TD]
[TD="align: right"]19/01/2018[/TD]
[TD] 88.350,00[/TD]
[TD][/TD]
[TD="align: right"]32395,00[/TD]
[TD="align: right"]55955,00[/TD]
[/TR]
[TR]
[TD="align: right"]29/12/2017[/TD]
[TD="align: right"]28/01/2018[/TD]
[TD]170.283,59[/TD]
[TD][/TD]
[TD="align: right"]11352,24[/TD]
[TD="align: right"]158931,35[/TD]
[/TR]
[TR]
[TD="align: right"]18/12/2017[/TD]
[TD="align: right"]17/01/2018[/TD]
[TD] 12.400,00[/TD]
[TD][/TD]
[TD="align: right"]5373,33[/TD]
[TD="align: right"]7026,67[/TD]
[/TR]
[TR]
[TD="align: right"]13/12/2017[/TD]
[TD="align: right"]12/01/2018[/TD]
[TD]107.100,00[/TD]
[TD][/TD]
[TD="align: right"]64260,00[/TD]
[TD="align: right"]42840,00[/TD]
[/TR]
</tbody>[/TABLE]

in E2 = IF(IF(MONTH(A2)<>MONTH(B2);C2/(B2-A2)*DAY(EOMONTH(A2;0)-DAY(A2)));IF(MONTH(A2)<>MONTH(B2);C2/(B2-A2)*DAY(EOMONTH(A2;0)-DAY(A2)));O2)

in F2 =C2/(B2-A2)*DAY(B2)


[TABLE="width: 1263"]
<colgroup><col span="3"><col span="12"></colgroup><tbody>[TR]
[TD="align: right"]01/11/2017[/TD]
[TD="align: right"]01/12/2017[/TD]
[TD="align: right"]01/01/2018[/TD]
[TD="align: right"]01/02/2018[/TD]
[TD="align: right"]01/03/2018[/TD]
[TD="align: right"]01/04/2018[/TD]
[TD="align: right"]01/05/2018[/TD]
[TD="align: right"]01/06/2018[/TD]
[TD="align: right"]01/07/2018[/TD]
[TD="align: right"]01/08/2018[/TD]
[TD="align: right"]01/09/2018[/TD]
[TD="align: right"]01/10/2018[/TD]
[TD="align: right"]01/11/2018[/TD]
[TD="align: right"]01/12/2018[/TD]
[TD="align: right"]01/01/2019[/TD]
[/TR]
[TR]
[TD][/TD]
[TD="align: right"]49367,5[/TD]
[TD="align: right"]21157,5[/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][/TD]
[TD="align: right"]20000[/TD]
[TD="align: right"]10000[/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="align: right"]17689,65517[/TD]
[TD="align: right"]39310,34483[/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][/TD]
[TD="align: right"]40300[/TD]
[TD="align: right"]201500[/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][/TD]
[TD="align: right"]41953,33333[/TD]
[TD="align: right"]47946,66667[/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][/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]

The ones that are marked in red are the expected results
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.

Forum statistics

Threads
1,223,904
Messages
6,175,295
Members
452,632
Latest member
jladair

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