The Object Browser is part of the VBE, and it allows you to look up definitions of objects, methods , properties, and constants. You can easily call up the object browser by pressing F2 (when you're in the VBE); it looks like this:
There's a lot of information available in the object browser. The first combo box allows you to select a specific library:
In this example, there are 6 libraries loaded:
Access contains the objects for Access itself
ADODB contains the ActiveX Data Objects
IceCream contains the current database, so that includes forms, reports , and so on
OWC10 contains the standard Microsoft Office XP objects
stdole contains some standard object features, which you'll never have to refer to
VBA contains the objects for Visual Basic for Applications
In Chapter 16 you'll see how to add more objects to this list.
The search window and results pane allows you to search for specific items. In the above diagram, I searched for ActiveForm , and it only occurs once - in the Access library, belonging to the Screen object. This is extremely useful if you know the name of something (such as a method or property) but can't remember which object it belongs to.
In the above diagram you can see that we were looking at < All Libraries >, so every object is shown, in alphabetical order. To look at the objects within the current database, you can just change to the IceCream entry:
This shows a list of all of the objects in the IceCream database. The Chapter 4 Code module is selected, and the Members pane shows all of the items in that module. Notice that no reports appear here - this is because the reports in the database don't have any code behind them. Only objects with code appear in the object browser.
The object browser is very useful: you really can learn a lot from just browsing around in it. You'll be amazed at how many objects, properties, and methods there are, and you're bound to find plenty that you didn't know existed.