
Picking up path name of Access Database
I am trying to get my VB5 application to pick up an Access 97 database using
DAO and the OpenDatabase connection.
The 'test.mdb' database resides in the same directory as the VB application.
I do not want to hardcode the path name into the application .
I thought that if no path was specified for the Access database then the
path of the directory where the VB application resides would be used as the
default path.
However even though the Access database resides in the same directory as the
VB5 application an error was returned telling me that the database could not
be found is returned.
Example :
dim cnn1 as database
set cnn1 = OpenDatabase("test.mdb")
Is there anyway the database path can be picked up without hardcoding the
full path name
Regards
Richard McKenna