Database Reference
In-Depth Information
Figure 9-7. IDE after setting the properties for your solution, project, and Windows form
Working with Controls
Now that you have your Windows Forms application in place, you can start working with the controls.
The basic element of any Windows application is the control, which plays a key role by providing the
visual meaning of the code functionality embedded in an application.
The most commonly used controls are Label, Button, TextBox, RadioButton, CheckBox, ListBox,
ComboBox, MenuStrip, and ContextMenuStrip. Applications cannot exist without these controls, so
you'll see how you can incorporate some of them into your application.
Try It: Working with the Label, TextBox, and Button Controls
In this exercise, you'll create a Windows Forms application with three labels, two text boxes, and a
button. The application will accept your name as input and then flash a “Welcome” message in the form
of a dialog box.
1. Go to the project named WinApp located under the solution named Chapter9,
which you created earlier (refer to Figure 9-7). Ensure that you are in the
Design view.
 
Search WWH ::




Custom Search