Can I upgrade an Access MDE database to Access 2007 ACCDE format using VBA only? -
I would like to allow the user to upgrade their back end database manually using access
Is this possible? I do not expect much from reading about this subject, but to confirm the expert it is impossible or hopefully solution >
If you are actually limited to only MED / ACCDE format, then it seems impossible
You can do this in an imperfect way, if you only use tables and questions , Is to create a new database in the desired format, and import tables and queries from the old database, the reason is that using the MED / ACCDE format, you can import form, modules and macros or import Can not be known.
Error 29045: Description: "You can not import, export, create, modify or rename any Forms, Reports, Pages or Modules in an ACCDE, MDE Try to produce an error or ADE database. "
If you are using only tables and questions, then depending on the example given in
You can go ahead as follows (in my scenario, I have a new database sub I am not able to do yoga as the current database so I temporarily need to import into the current database and then export it to the new database, otherwise just import directly into the new database.)
Due strNewDB string dims strOldDB as string dim dbOld as dirty slow dbNew database as dim dbNb database dim qry QueryDef set dbNew = DBEngine.CreateDatabase as (strNewDB, dbLangGeneral & Am P; "; PWD = xxxxx"), dbOncrypt set dbOld = DBEngine.OpenDatabase (strOldDB ,,, "; Pwd = xxxxx")) Import / Export tables in each TBL DBold TableDefs debug. Print tbl.name if left (tbl.name, 4) & lt; & Gt; "MSCS" then DSMM TransSDatabase ABIMport, "Microsoft Access", dBold.Name, AcTable, _TBL.name, "_temp_" & amp; Tbl.name DoCmd.TransferDatabase acExport, "Microsoft Access", dbNew.name, acTable, _ "_temp_" & amp; Tbl.name, tbl.name DoCmd.DeleteObject acTable, "_temp_" & amp; Tbl.name end then dbOld.QueryDefs debug.Print for each qry in the next tbl 'import / export queries qry.name DoCmd.TransferDatabase acImport, "Microsoft Access", dbOld.name, acQuery, _ qry.name, "_temp_" & Amp; Qry.name DoCmd.TransferDatabase acExport, "Microsoft Access", dbNew.name, acQuery, _ "_temp_" & amp; Qry.name, qry.name DoCmd.DeleteObject acQuery, "_temp_" & amp; Qry.name Next Curie
As mentioned earlier, when you use MDB / ACCB, you can use the application only. ConvertAccessProject
Comments
Post a Comment