Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

Practicals

223
PRACTICAL 13
Create a project
that determines the future
value of an
interest rate for given number of years. This method investment
a
gives the
at a given

interest. The future value is the sum of compound


principal amount and the accunulated
interest.
Future Value Investment amount * (1 + Interest rate) ^
=

years
Use labeled text boxes for the amount of investment, the interest
rate (as a
decimal fraction) and the number of years the investment will be held. Display
the future value in a formatted text box as currency. Include command buttons
for Calculate, Clear, Print and Exit. Format all dollar amounts.
Test data:
Amount Rate Years Future Value
2000 15% 4,022.71
1234.56 7.5% 1533.69

Solutiona:
Step 1: Design the form as shown in Fig. P. 13.1 below:

Future Value OX
lblPrn Principal Amount txtPrn

lbIRate nterest Rate txtRate

lblYears No. of Yeas txtYears

lblFV Future Value txtFV

cmdClear
IbICalc Calculate Clear

cmdExit
bIPrint Print Ext

Flg. P. 13.1

code window
Step 2: Type the following code in the
Code
of a n investment
Calculate future value
Purpose:
'Author:Mukesh N Tekwani

Private Sub cmdCalc_Click{)


investment
calculate the future value
of a n

Dim P As Double
Dim R As Double
Dim T As Double

You might also like