Click here to Skip to main content
15,896,727 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Dim futureValue As Decimal = Me.CalculateFutureValue(monthlyInvestment,yearlyInterestRate, years)
Posted
Updated 10-Dec-14 16:46pm
v3
Comments
Garth J Lancaster 10-Dec-14 22:26pm    
its not clear what you are asking
Member 9992980 10-Dec-14 22:27pm    
Could you please clarify your question. Are you asking what the code block does?

Quote:
A sub and a function are both subroutines, or sections of code that can be called in the program. The difference between them is that a function has a return value and a sub does not.

refer: Difference between Private Sub, Function and Class[^]
when you click calculate button it will fire the btnCalculate_Click event and inside that event your function(CalculateFutureValue) called with parameters and returned value will assign to futureValue
VB
Dim futureValue As Decimal = Me.CalculateFutureValue(monthlyInvestment,yearlyInterestRate, years)
 
Share this answer
 
v3
ok, I think I get what you're asking for

Button on form/html page, Tagged 'btnCalculate_Click'
-Calls-> Sub btnCalculate_Click
-Calls-> CalculateFutureValue

it looks like you are getting us to do your homework for you - this will stop, wont it ?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900