C
Chris F via AccessMonster.com
Hello All-
In my front end application (FCv3.accdb) I would like to import a table from
a password protected database called SMS.accdb.
In the code below, I am recieving an error message in the TransferDatabase
function Run-time error '3011', The Microsoft Office Access database engine
could not find the object t0ZRegistration.
Any thoughts on the code below would be greatly appreciated.
Thanks,Chris F
Dim oAcc
Dim db
Dim strForeignDB As String, strProjPW As String
strProjPW = "amy12345"
strForeignDB = PathFrontEnd(1) & "SMS.accdb"
Set oAcc = New Access.Application
Set db = oAcc.DBEngine.OpenDatabase(strForeignDB, False, False, ";PWD=" &
strProjPW)
oAcc.OpenCurrentDatabase strForeignDB
oAcc.DoCmd.TransferDatabase acImport, "Microsoft Access", CurrentProject.
FullName, acTable, "t0ZRegistration", "t0ZRegistration", True
Set db = Nothing
Set oAcc = Nothing
In my front end application (FCv3.accdb) I would like to import a table from
a password protected database called SMS.accdb.
In the code below, I am recieving an error message in the TransferDatabase
function Run-time error '3011', The Microsoft Office Access database engine
could not find the object t0ZRegistration.
Any thoughts on the code below would be greatly appreciated.
Thanks,Chris F
Dim oAcc
Dim db
Dim strForeignDB As String, strProjPW As String
strProjPW = "amy12345"
strForeignDB = PathFrontEnd(1) & "SMS.accdb"
Set oAcc = New Access.Application
Set db = oAcc.DBEngine.OpenDatabase(strForeignDB, False, False, ";PWD=" &
strProjPW)
oAcc.OpenCurrentDatabase strForeignDB
oAcc.DoCmd.TransferDatabase acImport, "Microsoft Access", CurrentProject.
FullName, acTable, "t0ZRegistration", "t0ZRegistration", True
Set db = Nothing
Set oAcc = Nothing