
Figure 1-1 A Windows Form in the Visual Studio IDE
Adding Forms to Your Project
Most projects will require more than one form. You can add and configure additional forms at design time, or you can create instances of pre-designed forms in code at run time.
To add a new form to your project at design time
1.
From the Project menu, select Add Windows Form. The Add New Item dialog box opens.
2.
Select Windows Form and type a name for the new form in the Name box. Click
Add to add the form to the development environment. You can add and configure as many forms as your application needs at design time. You can also create new instances of forms in your code. This method is most often employed when you want to display a form that has already been designed. In Visual Basic, you can access default instances of a form by referring to that form by name. For example, if you have a form named Form1 in your application, you can refer to it directly by its name, Form1.

No comments:
Post a Comment