无法打开为以前版本的应用程序创建的数据库 [英] Cannot open a database created for ado ith a previous version of your application

查看:825
本文介绍了无法打开为以前版本的应用程序创建的数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试使用ADOclass尝试oepn数据库(.mdb)文件时出错。



错误信息如下所述无法打开创建的数据库使用之前版本的应用程序



您能否告诉我如何解决问题。



我尝试过:



CDAO m_pReportDB;



sRepDbPath =Provider = Microsoft.ACE.OLEDB.12.0;+ CString(Data Source =)+ sRepDbPath;



if(m_pReportDB.Open(sRepDbPath))

I got a error when trying to oepn a database(.mdb) file througu using ADOclass.

The error message is mentioned below "cannot open a database created with a previous version of your application"

Could you please let me know how to solve the problem.

What I have tried:

CDAO m_pReportDB;

sRepDbPath = "Provider=Microsoft.ACE.OLEDB.12.0; " + CString("Data Source=") + sRepDbPath;

if (m_pReportDB.Open(sRepDbPath))

推荐答案

不要在快速答案下发布 - 如果您从文章中获得了代码,那么底部会显示添加评论或问题按钮该文章,导致电子邮件发送给作者。然后他们会被告知你希望与他们交谈。

在这里发布这个依赖于他们匆匆而过并意识到这是为了他们。



我修改了问题



然后几乎可以肯定你的数据库是在早期版本的ACE或JET中创建的数据库引擎 - 以后的引擎无法打开某些版本。

检查数据库,并(在备份之后)使用Access或类似功能将其转换为最新版本。
Don't post this under Quick Answers - if you got the code from an article, then there is a "Add a Comment or Question" button at the bottom of that article, which causes an email to be sent to the author. They are then alerted that you wish to speak to them.
Posting this here relies on them "dropping by" and realising it is for them.

"i modifed the question"

Then it's almost certainly that your DB was created in an earlier version of the ACE or JET DB engine - some versions cannot be opened by later engines.
Check the DB, and (after backing it up) convert it to the latest version using Access or similar.


这篇关于无法打开为以前版本的应用程序创建的数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆