MAPI Error Number -2147221242
CDO Error Number -2147746054
The information in this article applies to:
A CDO 1.21 application running as a Windows NT service fails with the following error message during user logon if the computer has Microsoft Outlook 97 or any version of the Exchange client as the default mail client:
"Collaboration Data Objects - [MAPI_E_UNKNOWN_FLAGS(80040106)]"
NOTE: The application runs fine interactively.
With Microsoft Exchange 5.5 SP2, CDO 1.21 adds a MAPI_NO_COINIT flag to MAPIInitialize (a call made to MAPI subsystem during user logon) whenever CDO 1.21 runs as a service application. Before the Microsoft Exchange 5.5 SP2 builds of MAPI, such as the one that comes with Microsoft Outlook 97, this flag was not recognized and returned the MAPI_E_UNKNOWN_FLAGS flag.
CDO 1.21 does not ship with Outlook 97 or the Exchange clients. It must be obtained and installed separately. See the "References" section of this article for more information.
Remove or rename the CDO.dll and upgrade to Outlook 98 or Outlook 2000, or install the MAPI subsystem that ships with Windows 2000. This last option is not suited for Windows 9x systems.