
Finding path of current database?
Seb,
Just a point of clarification... In Access there is no such thing as a
VBA macro. A macro is a macro, and vba is vba.
There may be more elegant ways of doing it, but this works...
Left(CurrentDb.Name, Len(CurrentDb.Name)-Len(Dir(CurrentDb.Name)))
- Steve Schapel, Microsoft Access MVP
Quote:
>Hi,
>How is it possible in a VBA macro to get the path of the current Access
>database? For example, if the Access mdb file path is "C:\My Documents\My
>DB.mdb", how can I get the "C:\My Documents\" programmatically?
>Thanks,
>Seb