My problem is as follow:
I Have two access database, both protected with different WorkGroup, then I need to Copy Table Products from DataBase A to DataBase B
for example:
But It doesn't workHTML Code:Dim A As dao.database Dim wks As dao.Workspace Dim strQuery As String DBEngine.SystemDB = PathOfMDWA Set wks = DBEngine.CreateWorkspace("", "UserNameA", "PasswordA") Set A = wks.OpenDatabase(App.path & "\A.mdb") strQuery = "SELECT * INTO PRODUCTS SELECT * FROM " & _ "[" & PathOfDataBaseB & ";Password=PasswordB;User ID=UserNameB;Jet OLEDB:System database=PathOfMDWB" & "].[Products]" A.Execute strQuery
Any Ideas?
Thanks




Reply With Quote