Question
mass and weight application in C# users allow to enter mass in kg or pound. * Calculate Button * User selects kg or lbs *
mass and weight application in C# users allow to enter mass in kg or pound.
* Calculate Button * User selects kg or lbs * Mass is entered; check that the mass entered is greater than 0 * If radioButtonPounds is entered, convert Mass to kg by dividing Mass by 2.2 * Weight is calculated - Weight = Mass * 9.8 * If weight is more than 1000 Newtons, display the message "Matter is too heavy." in labelComment; change the font color to Red * If weight is less than 10 Newtons, display the message "Matter is too light." in labelComment; change the font color to Blue * If weight is between 10 and 1000 Newtons, display the message "Matter is within limits." in labelComment; change the font color to Green * * Reset Button * Set the Kg radiobutton to be selected * Clear the input textbox * Clear the output labels * Set focus on the textbox * * Exit Button * Use a messagebox to confirm that the user wants to exit. * If yes, exit. If no, do nothing
application look like
mass in Kg (this is radio button) | calculate |
mass in Lbs(this is radio button) | reset |
Enter mass (this is textbox for user to enter a number) weight in newtons(this is label for output) comment label | exit |
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started