Step 4 – Add code to perform the calculation and display the amount due: 1. In the form’s Declarations section, declare a constant named HOURLY_RATE and set its value to be 12.00. 2. In the clearButton’s Click event, add code to clear all of the text box controls and the amountDueLabel control. 3. In the calculateButton’s Click event, declare two Single variables named hours and amount, and a Boolean variable name isConverted. Use the TryParse method to assign the value in the hoursTextBox control to the hours variable, storing the result from the TryParse method in the isConverted variable. Do the calculation using the hours and the hourly rate, and store the result in the amount variable. Display the amount value, formatted as currency, in the amountDueLabel control. 4. In the exitButton’s Click event, add code to end the program.
Use our Cheap Academic Essay service for guaranteed success!