1 Project Sonhein Products Page 404 #12
The solution should be put in a Folder Named CIS2656 on your memory stick or hard drive.
Do not save the Solution more than one folder deep. It will cause a problem.
2 Solution Name:
Example: P5SmithJ Solution
P5+Your name + First Initial Solution
3 Place your name on the title bar on each form.
Ex. SmithJ – P5 Sonheim Project
4 Your Assignment is to create an Application calculates change due.
6. use the following in the program
Add the following comment at the top of the coding
Project: P5 Sonheim Page 404 #12
Due Date: 2/23/2014
Program should have Option Strict and Explicit set to ON at top of the code
7. Depreciation values should be placed in a textbox
Declare Asset cost & Salvage value as double; Useful life as integer
Use tryParse to convert the cost, life and salvage value to variables
Use Boolean to determine if the Asset Cost and Salvage Value is valid. (blnCostisValid = Double.tryParse(…)
Only display the output if the Asset Cost and Salvage is valid. Use a nested If statement. If either is invalid, display appropriate error message. (see above)
Also use KeyPress to Validate Asset Cost and Salvage Value (also allow a decimal point)
Program should have SelectAll for 2 textboxes
If any of the 3 input values change, clear the output.
Load the listbox in form load event using a for loop (3 to 20)
Use a loop to display the answer in the textbox. You will need to also need to use ControlChars.NewLine and Financial.DDB method. See textbook problem/
This an example of the code that goes in the loop:
dblDepreciation = Financial.DDB(dblCost, dblSalvage, intLife, intPeriod)
It returns the depreciation amount for each year (period)
8 Run this program 4 times using the sample data in the forms (using snipping tool for error examples)
Using the Alt-Print Screen – Place the images in a file named P5LNameTestResults.docx
Compress and submit the program in the drop box. Submit the TestResults.doc file separately. Do not compress the TestResults.doc file.