1 form data from different database

  • Thread starter Thread starter Neil
  • Start date Start date
N

Neil

I created a form with several buttons, i am trying to incorporate in the
button wherein if i click the button, it will open a form in another database.

Will this be possible?

Please help me.

Thank you.
 
I created a form with several buttons, i am trying to incorporate in the
button wherein if i click the button, it will open a form in another database.

Will this be possible?

Please help me.

Thank you.

Adapted from VBA help on the OpenCurrentDatabase method.

You can use this as the code behind a Command Button Click event:

Public Sub OpenForeignForm()
Dim appAccess As Access.Application
Set appAccess = CreateObject("Access.Application")
appAccess.OpenCurrentDatabase "C:\FolderName\DatabaseName.mdb"
appAccess.DoCmd.OpenForm "frmMaintain"

End Sub
 
Back
Top