Can anyone give me the code that opens another Access Project and closes the current project. What I have tried doesn't seem to work. It opens the adp but doesn't change the current window to the new project.
Dim appAccess As Access.Application
Dim filePath As String
Set appAccess = Access.Application
' Open Access project.
filePath = "C:\localpubs.adp"
Set appAccess = New Access.Application
appAccess.OpenAccessProject filePath
Debug.Print " file path = "; filePath
Debug.Print " access app = "; appAccess.CurrentProject.Name
Thank you,
Jerry
Dim appAccess As Access.Application
Dim filePath As String
Set appAccess = Access.Application
' Open Access project.
filePath = "C:\localpubs.adp"
Set appAccess = New Access.Application
appAccess.OpenAccessProject filePath
Debug.Print " file path = "; filePath
Debug.Print " access app = "; appAccess.CurrentProject.Name
Thank you,
Jerry