SUMMARY
When using an existing 16-bit application compiled with
Microsoft Visual Basic version 4.0, the following error message may be
displayed if you are working with a Visual Basic 4.0 16-bit-built OLE client:
OLE Automation Error. -2147319784 (80028018)
During the installation of Microsoft Office 97 and Microsoft Visual Basic 5.0,
updated components and registrations entries may cause the above error message
only if you are using early binding and passing Collections from a Visual Basic
4.0 16-bit Automation client to a Visual Basic 4.0 Automation server. The
server can be either 16-bit or 32-bit.
This applies to any
combination of 16-bit / 32-bit collection interaction. This means that the same
problem will occur if the collection originates and is passed from a 32-bit
application to a 16-bit server as well. There are two ways to work around this
behavior:
Workaround 1 - When Source Code is Available (Best Solution)
To work around this behavior when you have the source code
available, you can re-write portions of the client that deal with collections
to use late binding rather of early binding. For example, a change you would
make to the Automation Client is:
instead of:
Dim X as Collection
use:
Dim X as Object
Set X = VBA.Collection
Workaround 2 - Existing Applications and No Access to Source Code
To work around this behavior in the situation where an existing,
compiled application is affected, certain changes must be made to the
Registration Database. These changes force TYPELIB.DLL to use the earlier
versions of the type libraries that released with Microsoft Visual Basic 4.0. A
registry file has been created by Microsoft that will change the registration
automatically.
The following files are available for download from the Microsoft
Download Center:
For
additional information about how to download Microsoft Support files, click the
following article number to view the article in the Microsoft Knowledge Base:
119591 How to Obtain Microsoft Support Files from Online Services
Microsoft scanned this file for viruses. Microsoft used the most
current virus-detection software that was available on the date that the file
was posted. The file is stored on security-enhanced servers that help to
prevent any unauthorized changes to the file.
Updating an Individual System
To update any single system, do the following:
- Copy the VB416FIX.EXE to a directory on the target system.
C:\TEMP works well.
- Double-click on VB416FIX.EXE to extract the file
VB416FIX.REG.
- Double-click on the VB416FIX.REG.
The following
message should be displayed: "Information in
<filename> has been successfully entered into the registry."
Including the VB416FIX.REG File in New Setups
To include the VB416FIX.REG file with the other components of a
Visual Basic 4.0 16-bit application, you must use the Application Setup Wizard
to build the distribution diskettes. Use the following steps:
- Run the Application Setup Wizard for Microsoft Visual Basic
4.0 (16-bit).
- Proceed through step 6 in the Setup Wizard as you normally
would.
- In step 7 in the Setup Wizard, click Add Files.
- Select the VB416FIX.REG file from the folder or diskette
where it is stored.
- Click OK, and then click Finish.
The Setup
Wizard will generate the compressed files for all of your components, including
the VB416FIX.REG file you included. When Setup Wizard is complete, you must
alter the SETUP.LST file. - Edit SETUP.LST in a text editor such as NotePad.
- In the section labeled [Files], you will find a line that
lists the VB416FIX.REG file The line will look similar to the following sample:
File2=1,,VB416FIX.RE_,VB416FIX.REG,$(AppPath),,,3/6/1997,247
- Edit the sixth (6) field to include the name of the .REG
file. The line should look like the following:
File2=1,,VB416FIX.RE_,VB416FIX.REG,$(AppPath),VB416FIX.REG,,3/6/1997,247
- Save the SETUP.LST file.
When a user runs the
SETUP.EXE, the VB416FIX.REG file will be registered automatically on the user's
system.
Microsoft is researching this problem and will post new
information here in the Microsoft Knowledge Base as it becomes available.