shebishelby
New member
- Local time
- Yesterday, 19:13
- Joined
- Jul 16, 2023
- Messages
- 3
I am working on this loan Management form that records information of clients that borrows money and records their details in a database. it then has a Repayment Schedule query that list out the number of installments, the due date the outstanding balance, and the principal after the installments are paid.
The formula i used is incorrect, its used to calculate fortnightly installments only. The Access file is attached below.
The formula i used is incorrect, its used to calculate fortnightly installments only. The Access file is attached below.
InstNo: [Nums].[Num] + ([Nums_1].[Num] * 10) + ([Nums_2].[Num] * 100)
Installment: Round(Pmt(([IntRate]/26)/100, [TotalPeriod], -[LoanAmt], 0, [PaymentMode]), 2)
Interest: Round(IPmt(([IntRate]/26)/100, [InstNo], [TotalPeriod], -[LoanAmt], 0, [PaymentMode]), 2)
Due Date: DateAdd("d", ([InstNo] - 1) * [PaymentType] * 14, [StartDate])
Outstanding: Round([LoanAmt] - ((Pmt(([IntRate]/26)/100, [TotalPeriod], -[LoanAmt], 0, [PaymentMode]) * [InstNo]) - TotInt([IntRate]/26)/100, [TotalPeriod], [LoanAmt], 1, [TotalPeriod], [PaymentMode])), 2)
Principal: [Installment] - [Interest]
TotRepayment: Round((Pmt(([IntRate]/26)/100, [TotalPeriod], -[LoanAmt], 0, [PaymentMode])) * [TotalPeriod] * 26, 2)
Interest: [TotRepayment] - [LoanAmt]
Function TotInt(IntRt As Double, TotPay As Double, TotAmt As Double, StartPeriod As Long, EndPeriod As Long, PaymentMode As Long) As Double
Dim i As Long
Dim j As Double
j = 0
For i = StartPeriod To EndPeriod
j = j + IPmt(IntRt / 26, i, EndPeriod - StartPeriod + 1, -TotAmt, 0, PaymentMode) * TotPay
Next i
TotInt = -Round(j, 2)
End Function