How to get parent MDB file for a MDE

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi

Can you tell me how to get parent Access MDB file name for a Access MDE file
Please reply ASAP

Thanks and Regards
Pritesh
 
If by 'parent' you mean that the MDB has a reference to the MDE ...

Public Sub TestSub()

MsgBox "The MDE " & CodeProject.FullName & " was called by " &
CurrentProject.FullName

End Sub

CodeProject refers to the project that contains the currently executing
code, while CurrentProject refers to the project that is active in the
Access UI.

The DAO equivalents are CodeDb and CurrentDb. The following DAO example
displays the same result as the example above ...

Public Sub TestSub()

MsgBox "The MDE " & CodeDb.Name & " was called by " & CurrentDb.Name

End Sub
 
Back
Top