Today there are many applications developed for finance related tasks. While working on Financial Projects I have completed many tasks according to client and user requirements. I want to share one of them with C# Corner readers to help them. Since they might have the same task,so I have decided to write this article.
So let us start with the basics.
Now create the project as:
- "Start" - "All Programs" - "Microsoft Visual Studio 2010".
- "File" - "New Project" - "C#" - "Empty Project" (to avoid adding a master page).
- Give the project a name, such as "interestratecalculator" or another as you wish and specify the location.
- Then right-click on Solution Explorer - "Add New Item" - "Default.aspx" page.
- Then drag two Textboxes, one Button, and one Label onto the "Default.aspx" page.
Then the <form> section of the Default.aspx page looks as in the following:
Now switch to design mode and double-click on the calculate button and use the following code to calculate the rate:
Then run the page which will look as in the following:
From the preceding view I am using one button to Calculate Interest Rate; one textbox for the original amount and one textbox for the interest rate which is applied on the original amount.
Now run the application and click on the Calculate button without entering the values which shows the following error as shown in the following:
Now enter the values and click on the calculate button, which shows the following output after Calculation:
- For detailed code please download the zip file attached above.
Now we have learned how to Calculate Interest Rate. I hope this article is useful for all students and beginners. If you have any suggestion related to this article please contact me.