9.16. Object Browser
It is
easy to be overwhelmed by the number of objects and what they do.
It's equally overwhelming when you realize the
number of objects that might be available to your machine without
your being aware of it.Microsoft Office 97, 2000, and XP provide a powerful programming
environment based on the Visual Basic for Applications language
(similar to VBScript). Within this environment, there is an object
browser, which allows you to browse objects installed on your system
and investigate the methods and properties associated with them. You
do not actually have to write any code to take advantage of the
Object Browser.
|
Microsoft Word or Excel:
- Select
ToolsMacro
Visual Basic Editor. This
will start the VBA environment. - Select Tools
References. The dialog box shown in Figure 9-2 will
appear.
Figure 9-2. Object References dialog box

references you wish to use. The reference name for the WSH
Wscript object is Microsoft Windows Script Host
Object Model, and the FileSystem object is Microsoft Scripting
Runtime.Once you have selected the libraries you wish
to reference, select the OK button.Now press the F2
key. This will display the object browser window.Select
the object you wish to browse from the drop-down list in the upper
left-hand corner. The Classes window on the left lists all objects
related to the component, while the right window lists all methods
and properties related to the selected object. Figure 9-3 shows the Object Browser viewing the
FileSystem object.
Figure 9-3. Object Browser
