pannai
01-09-2007, 12:28 AM
Hi
I am using Access DB to load data to excel. I have placed the DB in the same directory as that of excel file. So I have coded Db connection as followsSet dbcon = New ADODB.Connection
dbfile = "pg.mdb"
dbcon.Open "Provider=Microsoft.Jet.Oledb.4.0;data source=" & dbfile & ";"
When I open the excel file using File -> open, it is working fine. But if I open the excel file by double click or from recent files option, it gives me the following error
"Could not fild file c:\documents and settings\administrator\pg.mdb"
Can anyone help me?
Thanks in advance
I am using Access DB to load data to excel. I have placed the DB in the same directory as that of excel file. So I have coded Db connection as followsSet dbcon = New ADODB.Connection
dbfile = "pg.mdb"
dbcon.Open "Provider=Microsoft.Jet.Oledb.4.0;data source=" & dbfile & ";"
When I open the excel file using File -> open, it is working fine. But if I open the excel file by double click or from recent files option, it gives me the following error
"Could not fild file c:\documents and settings\administrator\pg.mdb"
Can anyone help me?
Thanks in advance