Hi,
I am trying to access a Microsoft Jet Database file (.mdb) through an MFC Application.
When I call the CreateWorkspace() method, there are no exceptions generated but I get the following error:
Operation is not supported for this type of object. (Error 3251)
My code:
CdbDBEngine dbEngine;
CdbWorkspace dbWspace;
int nErrCnt;
try
{
dbWspace = dbEngine.CreateWorkspace( "MyWorkSpace", "Admin", "", dbUseJet );
catch( CdbException* e )Quote:}
{
AfxMessageBox( e->m_strError );
e->Delete();
if( nErrCnt = dbEngine.Errors.GetCount() > 0 )Quote:}
{
long lIndex = nErrCnt-1;
CdbError dbError = dbEngine.Errors[lIndex];
AfxMessageBox( dbError.GetDescription() );
Has anyone experienced a similar problem?Quote:}
Thanks.
-----------------** -- Posted from CodeGuru -- **-----------------
http://www.codeguru.com/ The website for Visual C++ programmers.