Select the product you need help with
- Internet Explorer
- Windows Phone
- More products
INFO: Maintaining Binary Compatibility in Components with ADOR
Article ID: 216389 - View products that this article applies to.
This article was previously published under Q216389
Originally, ADOR was designed to be a standalone component. However, as ADO has evolved in design and use, this is no longer ADOR's purpose. ADOR is now only a sub to the MSADO15.DLL and exists only to maintain backward compatibility.
Recompiling a Visual Basic project that uses Binary Compatibility and ADOR generates a warning to the following effect:
The dialog box offers a choice to either accept and break the compatibility or edit and preserve the return types or arguments.
"...module has arguments and/or return type that is incompatible with a similar declaration in the version compatible component.
Original Definition: Function function_name as ADOR.Recordset20
Current Definition: Function function_name as ADOR.Recordset"
The newer version of the ActiveX Data Objects Recordset (ADOR) library uses newer interfaces for the Recordset object. If your component exposes Recordset objects, recompiling with the newer version of ADOR will cause your component to expose those new interfaces and break Binary Compatibility, which is why the dialog box appears.
ADOR (MSADOR15.DLL) is a subset of ADODB (MSADO15.DLL). ADOR only exposes the Recordset interface. ADOR and ADODB share identical GUIDs for shared objects, such as the Recordset, under the same version of ADO, and thus there is no need to explicitly use ADOR in any application development.
If you originally built your component with ADOR 2.0 and you now have MDAC 2.1 installed, you can replace the reference to ADOR 2.1 with a reference to the ADO 2.0 type library (MSADO20.TLB). This type library was designed to allow you to use ADO 2.0 interfaces even though ADO 2.1 is installed on the machine. For more information on this type library, please see article Q201576 in the REFERENCES section below. Once you have referenced the ADO 2.0 type library, you can replace all code that uses the ADOR.Recordset syntax with code that uses the ADODB.Recordset syntax. After these changes are made, the project should compile without complaining about a break in Binary Compatibility.
If you originally built your component with ADOR 1.5 and you now have MDAC 2.0 or 2.1 installed on your machine, please read article Q195049 referenced below. While this article was written for maintaining Binary Compatibility for components originally compiled with ADO 1.5, the same information applies to ADOR 1.5. Both ADO and ADOR 2.0 can expose (but not create) Recordset15 interfaces. Both ADO and ADOR 2.1 can expose (but not create) Recordset15 and Recordset20 interfaces.
For additional information about ADOR, please see the following articles in the Microsoft Knowledge Base:
201576 INFO: ADO 2.1 Ships with an ADO 2.0 Type Library
195049 HOWTO: Maintain Binary Compatibility in Components Exposing ADO
Article ID: 216389 - Last Review: May 8, 2003 - Revision: 2.2