Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error '3024' File not found

Status
Not open for further replies.

LostSon

Technical User
Aug 29, 2005
5
US
Hello,

I get error '3024', Could not find file 'G:\...' when I try both of these pieces of code. I have checked the spelling and the file is there. Please help.

#1

Public Sub LoadTables()

Dim strSQL As String
Dim dbAAPCost As Database
Set dbAAPCost = CurrentDb


strSQL = "INSERT INTO tblBOM SELECT * FROM " & _
"[G:\CostDataBase\BPCS_Extract.mdb].tblBOMExtract;"

dbAAPCost.Execute strSQL, dbFailOnError


End Sub
______________________________________________________________________________________________

#2

Public Sub LoadTables()

DoCmd.TransferDatabase acImport, "Microsoft Access", _
"G:\CostDataBase\BPCS_Extract.mdb", acQuery, "qryTest", "tblTest"

End Sub



Thanks.
 
What about this ?
strSQL = "INSERT INTO tblBOM SELECT * FROM tblBOMExtract" _
& " IN 'G:\CostDataBase\BPCS_Extract.mdb'"

You may even, perhaps, get rid of the single quotes.

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Same error. Do I need to do anything before executing the SQL string? Open the external DB, or something?
 
Why not link the external table ?

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 

Guess I'll have to for now. It just drives me nuts when I know something should work and I can't figure out why it isn't.

Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top