j ai un petit probleme
je me connecte a la base de donnee acces..mais il n arrete pas de me retourner un error comme quoi ADOje sais pas quoi est peut etre pas installer..
il fo faire quoi?
est ce la bonne syntxe pour se connecter..
merci
extrai du code
#import "C:\WINNT\ServicePackFiles\i386\msado15.dll" \
no_namespace rename("EOF", "EndOfFile")
inline void TESTHR(HRESULT x) {if FAILED(x) _com_issue_error(x);};
void GetRowsX(void);
bool GetRowsOK(_RecordsetPtr pRstTemp,int intNumber,
_variant_t& avarData);
void PrintProviderError(_ConnectionPtr pConnection);
void PrintComError(_com_error &e);
struct InitOle {
InitOle() {CoInitialize(NULL);}
~InitOle() {CoUninitialize();}
} _init_InitOle_;
_bstr_t strCnn("Provider={Microsoft Access Driver (*.mdb)};DBQ=DATA.mdb;;DefaultDir=C:\Documents and Settings\antoinec\Desktop\ado\1\;"
"Initial Catalog=pubs;User Id=;Password=;");
void PrintComError(_com_error &e)
{
_bstr_t bstrSource(e.Source());
_bstr_t bstrDescription(e.Description());
// Print Com errors.
printf("Error\n");
printf("\tCode = %08lx\n", e.Error());
printf("\tCode meaning = %s\n", e.ErrorMessage());
printf("\tSource = %s\n", (LPCSTR) bstrSource);
printf("\tDescription = %s\n", (LPCSTR) bstrDescription);
}