TransferText woes

  • Thread starter Thread starter Eric Frohmann
  • Start date Start date
E

Eric Frohmann

Access XP (2002)

This line used to work in my code:

DoCmd.TransferText acExportDelim, "specImportFRIData",
"prgTblExportStandData", stTargetFile

Now it doesn't. I've installed several SP's as per MS recommendations. Now,
when attempting the DoCmd, stTargetFile is converted to c:\dir\file#ext from
c:\dir\file.ext. Any ideas why?

As an aside, where is the specification file for the TransferText command
stored? in the DB itself?

TIA
 
Specifically...

stTargetFile = "C:\Data\Ww data\Access PFRS\FRIData\DataUpload\wwtest.csv"

DoCmd.TransferText acExportDelim, "specImportFRIData",
"prgTblExportStandData", stTargetFile

triggers the Error trap in the routine and Err.Description contains:

The MS Jet DB engine could not find the object 'wwtest#csv'. Make sure the
obj exists and that you spell its name and the path name correctly.
 
Have you tried including single quotes with stTargetFile either

stTargetFile = "'C:\Data\Ww data\Access PFRS\FRIData\DataUpload\wwtest.csv'"

or

DoCmd... "'" & stTargetFile & "'"

Kelvin
 
Thanks for the reply. I figured it out eventually - it was an incorrect
export specification. None of the errors showed this clearly, so I was
chasing shadows...
 
Back
Top