Question: Write a program to calculate three monthly values associated with a mortgage. See image below for field list. The program should use the event procedure
Write a program to calculate three monthly values associated with a mortgage. See image below for field list.

The program should use the event procedure below.
Private Sub btnCalculate_Click(...) Handles btnCalculate.Click Dim annualRateOfInterest, monthlyPayment, begBalance As Double
Dim intForMonth, redOfPrincipal, endBalance As Double
InputData( annualRateOfInterest, monthlyPayment, begBalance )
Calculate( annualRateOfInterest, monthlyPayment, begBalance,
intForMonth, redOfPrincipal, endBalance )
DisplayData( intForMonth, redOfPrincipal, endBalance ) End Sub
The interest paid each month is the monthly rate of interest (annual Rate of Interest / 12) applied to the balance at the beginning of the month. Each month the reduction of principal equals the monthly payment minus the interest paid.
At any time, the balance of the mortgage is the amount still owed; that is, the amount required to pay off the mortgage. The end of month balance is calculated as [beginning of month balance] - [reduction of principal]. The code should not be too difficult, I'm just unsure of when you use ByRef and ByVal.
Mortgage Annual rate of Interest: 5 Monthly payment: 1932.56 Beg. of month balance 357819.11 Calculate Data for Month Interest paid for month: $1.490.91 Reduction of principal: $441.65 End of month balance $357.377.46
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
