As indicated in the article referred to in Remou's answer, dbEncrypt
requires a password:
CompactDatabase firstdb, seconddb, ";pwd=secret", dbEncrypt
It also seems that an upgrade can't be done in the same call, thus I needed two lines to upgrade an older MDB
to an encrypted ACCDB
. Note the placement of the password in each line:
CompactDatabase oldMDB, encryptedDb, ";pwd=secret", dbEncrypt
CompactDatabase encryptedDb, upgradedDb, , dbVersion120, ";pwd=secret"
The following did not work and gave the Invalid argument
error:
CompactDatabase oldMDB, encryptedAccdb, ";pwd=secret", dbEncrypt + dbVersion120