Microsoft Office Tutorials and References
In Depth Information
Using the Project window
Using the Project window
When you work in the VB Editor, each Excel workbook and add-in that’s currently
open is considered a project . You can think of a project as a collection of objects
arranged as an outline. You can expand a project by clicking the plus sign (+) at the
left of the project’s name in the Project window. You contract a project by clicking
the minus sign (–) to the left of a project’s name. Figure 13-2 shows the Project
window with three projects listed (one add-in and two workbooks).
Figure 13-2: A Project window with three projects listed
If you try to expand a project that is protected with a password, you are
prompted to enter the password.
Every project expands to show at least one “node” called “Microsoft Excel
Objects.” This node expands to show an item for each worksheet and chart sheet in
the workbook (each sheet is considered an object) and another object called
ThisWorkbook (which represents the Workbook object). If the project has any VBA
modules, the project listing also shows a Modules node with the modules listed there.
A project may also contain a node called Forms (which contains UserForm objects)
and a node called Class Modules (which contain Class Module objects). This topic
doesn’t cover the objects contained in the UserForms node or Class Modules node.
By default, all projects are named VBAProject. In the Project window, the workbook
name appears (in parentheses) next to the project name. For example, a project may
appear as
VBAProject (budget.xls)
You may prefer to change the name of your project to a more descriptive name.
To do so, select the project in the Project window. Make sure that the Properties
window is displayed (press F4 if it’s not displayed) and change the name from
Search JabSto ::

Custom Search