Visual Basic has some built in financial calculations.
The following is how I would code it in VB. Any thoughts on C# equivalent? It is computing a payment amount for a loan.
Hi again,
There isn't an equivalent function in C#. However, you can add a reference to the Microsoft.VisualBasic.DLL in your C# project and use its functions. I don't imagine that this is often a great idea, but regarding the financial functions, there are some good ones in VB, so I've used them like this before.
1) Add a reference to Microsoft.VisualBasic DLL in your project.
2) Add
Code:
using Microsoft.VisualBasic;
to the top of the class where you want to use your financial functions.
3) Use your Pmt function as so: