Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use Visual studios C++ Create FORM 1 and Designer Form code 1. Form has: a Paint button, Two Textboxes, Four Labels, a Submit button, a

Use Visual studios C++ Create FORM 1 and Designer Form code

1. Form has:

a Paint button, Two Textboxes, Four Labels, a Submit button, a Clear button, an Exit button.

what you have are four buttons: with the text displayed on the buttons as: Paint, Submit, Clear, Exit.

Textboxes: for entering Name and Age.

Labels: first two are positioned next to the textboxes, and describe the textboxes. For example, the label next to NameTextBox will display Name. The other two labels are either below or to the right of Submit button, and will display the name and age entered into the textboxes.

Clicking each button leads to actions as described below.

At start, only Paint button is visible (This means no other control is visible). In addition, the Clear and Exit buttons are also disabled. Clicking Paint button changes the color of the form, sets the color for all four buttons, makes the two TextBoxes and the remaining three buttons visible, disables the Paint button.

The Clear and Exit buttons remain disabled.

color of form and buttons: you may interpret color here to mean the background color (not the color of text displayed) and may choose any color.

User enters Name into the first textbox, Age into the second textbox, and clicks Submit.

When submit is clicked, the name and age are displayed in labels, Clear and Exit buttons are enabled.

When clear is clicked, both textboxes and labels displaying Name and Age are cleared and form is ready for new input.

When Exit is clicked, application exits.

Add tooltips for: All buttons, and the two textboxes.

Add keyboard shortcuts for each button as well. (optional:see comment below in blue about shortcut for Submit)

Set Accept Button to Paint Button.

The form should start at the center of the screen.

Naming Controls: the two labels by the side of the textboxes do not need custom names. Name all other controls in a sensible way. (for example, the label to the left of nameTextbox may be just label1; the label displaying the name back to the user should be named something like nameLabel, or labelName, or lblName).

The guideline is: controls which serve only as captions, and which do not change or participate in events need not be renamed. The buttons participate in events, the textboxes and name and age labels change; so they all need to be renamed in informative ways. Another way to think about this is: if a control is referred to from your form1.cs (the code), then it is preferred that the control has an informative name. (An event is an action like a button click. Participating in an event - means the control is referred to in the code you write inside the button click method to execute actions.)

It is fine if you leave the form name unchanged, as form1.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

SQL Server Query Performance Tuning

Authors: Sajal Dam, Grant Fritchey

4th Edition

1430267429, 9781430267423

Students also viewed these Databases questions