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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

TransferDatabase Erorr 3011 when late binding

Status
Not open for further replies.

RobS23

Programmer
Jun 4, 2001
161
GB
Hi

I'm having to pull tables out of an Access db. I'm using late binding because it has to work across multiple versions.

Early binding everything is happy

However, when I use late binding the statement

apAccess.DoCmd.TransferText acExportDelim, , "exp", "C:\myfile.txt", True

Throws error 3011 - File not found

Any suggestions 'cause it's getting me down
 
RobS23,

Since you are using late binding and you are no longer referencing the Access object you need to declare "acExportDelim" or just substitute its name with its value, as in:

apAccess.DoCmd.TransferText 2, , "exp", "C:\myfile.txt", True

Hope that helps,
-GS
 
Thanks

Can't believe that i had completly forgotten that! That's 18 months of ,net and no v6.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top