Get Home Directory

jeffbruce

Registered User.
Local time
Today, 13:05
Joined
Jun 29, 2007
Messages
19
I have an Access database linked with VB.

Here's what I'd like to do:
Use the TransferText method to create a file (which I have done) and save it in the same directory as the Access database.

Here's what I'd like to know:
Is there is a built-in VB function for retrieving the path name of the Access database and storing it as type String?

e.g.
Say I have an Access database called C:\idioteque.mdb
I want a method that returns C:\

another e.g.
Say I have an Access database called F:\PinkerSlipCanyon\IndustrialPaycheck\HunchMonkey\paydirt.mdb
return F:\PinkerSlipCanyon\IndustrialPaycheck\HunchMonkey\

Thanks.
 
Umm... Did you search at all?

CurrentProject.Path

So, for a string:

YourStringName = CurrentProject.Path
 
Exactly what I was looking for, thanks a million.
 

Users who are viewing this thread

Back
Top Bottom