Can I convert currentDB to a path to the database.

  • Thread starter Thread starter nod
  • Start date Start date
N

nod

I have some sample code written for VBA which accesses the database
using db.this = currentDB
I would like to combine the code with another example that is written
in VB6 and uses ADO. This code accesses the database using a path to
it like C:\pathTo\my.mdb

WHat do I need to do I convert the first code so that I can use a path
to the database.

TIA
Nod
 
Not exactly sure I understand what you're after, but CurrentDb.Name gives
you a string value containing the complete database filespec (path +
filename), whereas CurentProject.Path gives you the path only.

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia

Office DevCon 2007. Sydney, Australia 3rd-4th Nov. Will you be there?
http://www.block.net.au/devcon/index.htm
 
Back
Top