Adding a Form to Your Project

     

Forms are separate objects that you add to your VBA projects. To do this, open the Visual Basic Editor and either select Insert, UserForm or drop down the Insert toolbar button (the second from the left) and select UserForm. As you can see in Figure 13.1, VBA performs the following tasks in response to this command:

  • It adds a Forms branch to the project tree in the Project Explorer.

  • It creates a new UserForm object and adds it to the Forms branch.

  • It displays the form in the work area.

  • It displays the Toolbox.

Figure 13.1. Selecting Insert, UserForm adds a new form to the project.

graphics/13fig01.jpg



Absolute Beginner's Guide to VBA
Absolute Beginners Guide to VBA
ISBN: 0789730766
EAN: 2147483647
Year: 2003
Pages: 146

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net