Question Description
Summary: In this assignment you create one main form and two additional forms, as shown below for each form layout.
- The main form hosts the information from other two forms to collect quizzes scores and projects scores. It also has input for Final score and then to calculate the Letter Grade and display it.
- On the main form there are two buttons: Quizzes Total and Projects Total such that when you click on Quizzes Total, Quizzes form opens and allows user to enter scores for quizzes. And when you click on Projects Total, Projects form opens and allows user to enter projects scores.
- Upon returning from either Quizzes or Projects form, OK button calculates the totals and displays on the main form and closes the form. Cancel button of either Quizzes or Projects form returns to the main form without any calculations.
- Then you allow user to enter the Final score on the main form.
- Once you have all the information: Quizzes, Projects and Final, clicking on Grade button, calculates the Grade (A, B, C, D, F) displays in the label control across from Grade. No need for error checking. Please make sure when you test the program, you enter all the information and for any missing item enter 0.
- Clear button clears the main form data and Exit button closes the main form, i.e., the enter program.
Instructions:
- Create a new project and name it as yourlastname-firstname-Assignment7. Save this project in VB folder you created earlier.
- Change forms title to: Your full name Assignment 7 – Multiform.
- Main form contains (see main form layout below):
- five buttons: Quizzes Total, Projects Total, Grade, Clear and Exit
- five labels: display Quizzes Totals, Project Totals and Grade. Display Final and Grade labels
- one textbox to input Final score. Clear button to clear the main form and Exit to close the mail form
- Quizzes form contains (see quizzes form layout below):
- four labels to display Quiz 1, Quiz 2, Quiz 3, Quiz 4
- four textboxes to input score for each quiz
- two buttons: OK to add the quizzes scores and return to the main form & Cancel to return to the main form without any calculations
- Projects form contains (see projects form layout below):
- five labels to display Project 1, Project 2, Project 3, Project 4, Project 5
- five textboxes to input score for each project
- two buttons: OK to add the projects scores and return to the main form & Cancel to return to the main form without any calculations
- To calculate the grade, use the following percentages for each activity:
- Quizzes 30% (maximum score is listed on quizzes form, see below in form layout)
- Projects 30% (maximum score is listed on project form, see below in form layout)
- Final 40% (score from 100)
HINT: make sure when you enter % you divide by 100. For example: calculate the 30% of 80, you do this:
(80 * 30) / 100 = 24.
So if someone gets 70 for quizzes and 80 for projects and 85 for final, the grade is: (78 * 30)/100 + (80 * 30)/100 + (85 * 40)/100 = 81.4 which is a B.
- Items to note:
- Variables names must follow the conventions and rules explained earlier and must have proper data type for the values that will be stored in them. Choose variable data types as Single.
- Control names should use the naming convention we have covered in this class.
- Appearance of the forms is very important; Make sure that your design is clean; Spelling is important.
- You will write the code for buttons in each form: main form ( Grade, Clear and Exit buttons), quizzes form (OK and Cancel buttons), and projects form (OK and Cancel buttons).
- Avoid double-clicking on labels and textboxes controls to create unnecessary code. If you do, please delete them.
- Run the program, click Quizzes Total button and enter scores for quizzes then click on OK to return to the main form; click on Projects Total button and enter scores for projects then click on OK to return to the main form; enter Final score and click on Grade button to display the grade.
- To save the project, from File, select Save All.
- Continue with SaveAll after making changes.
- Once project is complete, open File Explorer; open VB folder and you will see a folder named: yourlastname-firstname-Assignment7. This folder contains a folder and a solution file with SLN extension. Both are named the same. Solution file (.SLN) and the folder containing VB necessary files to run the project.