visual c++ - connecting to access database using MFC CDatabase in VS2012 and windows 8 x64 -
to connect access database programming mfc, using visual studio 2012 update 1 installed on windows 8 x64, following code throws exception, did not happened before in vs2010 , windows 7 x64. there thing changed odbc manager , how should change connection string.
cdatabase db; db.openex(text("odbc;driver={microsoft access driver (*.mdb, *.accdb)};dsn='';dbq='d:\\databases\\a.mdb'"); and exception message:
'data source name not found , no default driver specified' it not work accdb file too.
cha in comments correct since default x64 odbc driver present in windows 8 mfc applications compiling in win32 platform necessary install odbc driver in x86. downloaded here: http://www.microsoft.com/en-us/download/details.aspx?id=13255
Comments
Post a Comment