Reputation: 477
I am trying to convert MS Access
database from version 2000
to 2007
or 2010
. I have to achieve this using Python
.
If I install MS Access 2007
or MS Access 2010
, it works. But I want to do this without installing these versions of MS Access
. I tried installing MS Access 2010 Runtime
, but not working.
I have tried pypyodbc
module but it is only working for mdb
database. I have also tried following with win32com.client.Dispatch()
:
Access.Application (ConvertAccessProject)
JRO.JetEngine (CompactDatabase)
DAO.DBEngine (CompactDatabase)
None of above is working.
I searched a lot on the internet but did not find any solution till now. Let me know if there is any solution for this.
Upvotes: 1
Views: 776
Reputation: 123399
If I install MS Access 2007 or MS Access 2010, it works. But I want to [convert an entire Access application from Access 2000 to Access 2007 or Access 2010] without installing these versions of MS Access. I tried installing MS Access 2010 Runtime, but not working.
Your objective is impossible to achieve. In order to convert an entire Access application (with forms, reports, module code, etc.) from Access 2000 to Access 2007 or Access 2010 you must have a full version of Access 2007 or Access 2010 installed because that's where the conversion code is.
Upvotes: 1
Reputation: 55806
I have only had troubles with Python, but it could be this:
Access.Application.ConvertAccessProject sourcefile, targetfile, acFileFormatAccess2007
Or, as the constant probably is unknown to P:
Access.Application.ConvertAccessProject sourcefile, targetfile, 12
Perhaps you need to be a bit more explicit:
ap = win32com.client.Dispatch("Access.Application")
ap.ConvertAccessProject(s, t, 12)
Upvotes: 0