unresolved external symbol _CLSID_MSDAINITIALIZE, any idea? 
Author Message
 unresolved external symbol _CLSID_MSDAINITIALIZE, any idea?

Can anyone tell what I should about this message?

#define DBINITCONSTANTS file://Initialize OLE DB constants...
#define INITGUID        // ...once in each app

#include <afxwin.h>     // For shameless use of CString
#include <comdef.h>
#include <string.h>
#include <stdio.h>

#include <oledb.h>      // OLE DB include files
#include <oledberr.h>
#include <msdaguid.h>   // ODBC provider include files
#include <msdasql.h>    // MSDASQL include files
#include <sqloledb.h>   // SQLOLEDB include files
#include <MSjetoledb.h> // MSJETOLEDB include files
#include <msdaora.h>    // MSDAORA include files
#include <msdasc.h>        // OLE DB Service Components

   CoInitialize(NULL);

   // Obtain Access To The OLE DB - ODBC Provider

   file://CoCreateInstance(CLSID_MSDASQL, NULL, CLSCTX_INPROC_SERVER,

//      IID_IDBInitialize, (void **) &pIDBInitialize);

// Create an instance of the OLE DB Initialization Component.
 CoCreateInstance(CLSID_MSDAINITIALIZE, NULL, CLSCTX_INPROC_SERVER,
  IID_IDataInitialize,(void**)&pIDBInitialize);

// Create an instance of CLSID_MSDASQL with supported Services.
 pIDBInitialize->CreateDBInstance(CLSID_MSDASQL, NULL,
 CLSCTX_INPROC_SERVER, NULL, IID_IDBInitialize,
  (IUnknown**)&pIDBInitialize);

Thanks in advance!



Tue, 27 Aug 2002 03:00:00 GMT  
 unresolved external symbol _CLSID_MSDAINITIALIZE, any idea?
I figured it out, I need to include msdasc.lib in the object/libraray module


Quote:
> Can anyone tell what I should about this message?

> #define DBINITCONSTANTS file://Initialize OLE DB constants...
> #define INITGUID        // ...once in each app

> #include <afxwin.h>     // For shameless use of CString
> #include <comdef.h>
> #include <string.h>
> #include <stdio.h>

> #include <oledb.h>      // OLE DB include files
> #include <oledberr.h>
> #include <msdaguid.h>   // ODBC provider include files
> #include <msdasql.h>    // MSDASQL include files
> #include <sqloledb.h>   // SQLOLEDB include files
> #include <MSjetoledb.h> // MSJETOLEDB include files
> #include <msdaora.h>    // MSDAORA include files
> #include <msdasc.h>        // OLE DB Service Components

>    CoInitialize(NULL);

>    // Obtain Access To The OLE DB - ODBC Provider

>    file://CoCreateInstance(CLSID_MSDASQL, NULL, CLSCTX_INPROC_SERVER,

> //      IID_IDBInitialize, (void **) &pIDBInitialize);

> // Create an instance of the OLE DB Initialization Component.
>  CoCreateInstance(CLSID_MSDAINITIALIZE, NULL, CLSCTX_INPROC_SERVER,
>   IID_IDataInitialize,(void**)&pIDBInitialize);

> // Create an instance of CLSID_MSDASQL with supported Services.
>  pIDBInitialize->CreateDBInstance(CLSID_MSDASQL, NULL,
>  CLSCTX_INPROC_SERVER, NULL, IID_IDBInitialize,
>   (IUnknown**)&pIDBInitialize);

> Thanks in advance!



Tue, 27 Aug 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Unresolved external _CLSID_MSDAINITIALIZE in MFC Project

2. wcschr: unresolved external symbol...

3. NOVICE: Unresolved external symbol?

4. unresolved external symbol : why?

5. unresolved external symbol

6. LNK2019: unresolved external symbol

7. PxSQLScript.obj : error LNK2001: unresolved external symbol "class ATL::CTraceCa

8. VC++ 7 Link Error : unresolved external symbol

9. Linking error 2019 unresolved external symbol _main when porting to .NET

10. Linking error 2019 unresolved external symbol _main ...

11. unresolved external symbols

12. Error LNK20001 unresolved external symbol main.

 

 
Powered by phpBB® Forum Software