Configuring a Visual Basic Project
Although you can use Caché objects from a Visual Basic project without any configuration, you must configure your Visual Basic project if you want to use early binding. Early binding is a feature of Visual Basic that allows you to declare objects so they carry information about their type. For example, with early binding, you can specify:
Dim MyList as CacheActiveX.SysList
Early binding also provides pop-up menus which show you possible elements to use to finish a statement. For example, you can choose from a list of possible object types to associate with a new instance:
![generated description: vbcontinuation](images/blax_vbcontinuation.png)
Early binding also provides pop-up syntax windows for Caché elements:
![generated description: vbhelpwin](images/blax_vbhelpwin.png)
To use early binding, select the project references as outlined below. The Visual Basic project configuration process consists of selecting the project references. Whenever you create a new Visual Basic project, you must add CacheActiveX.dll to your project references. To do this:
-
Within Visual Basic, open the references window using the References menu item in the Project menu.
-
Select the check box to the left of this DLL.
If this DLL does not exist in a list of available references:
-
Click on the Browse button.
-
Find CacheActiveX.dll in your Program Files\Common Files\Intersystems\Cache directory and double-click it.
If you are working with legacy code and must use the older DLL, CacheObject.dll, you can add that to your project references in a similar way. CacheObject.dll is located in the <installation-root>\bin directory.