Export to CSV

cross5900

Blarg!
Local time
Today, 17:27
Joined
Mar 24, 2006
Messages
92
I am trying to do something very simple but for some reason I can not get this to work.

I have a linked .csv table: (s:\pctools\admin\template\sadirect\SellerFeesReport.CSV)

and I am using query 'dupSellerFeesReport' that does a simple group by to get rid of all duplicate accounts (if they exist)

my code below "should" work but for some reason it keeps running a run-time error.

Code:
DoCmd.TransferText acExportDelim, "", "dupSellerFeesReport", "s:\pctools\admin\template\sadirect\SellerFeesReport.CSV", false

Run-time error '3625':
The text file specification 'SellerFeelsReport Link Specification' does not exist. You cannot import, export, or link using the specification.

Can anyone help me out? Thanks in advance.
 
Nevermind. Attempted a different approach.

Used a Make-Table query to create a real table from the linked .csv table.
Then exported from that table, worked just fine.
 
Too late now but you have to provide a Specifcation to export with that command, for example
DoCmd.TransferText acExportDelim, strSpec, strFile, "Z:\strTxtFile & ".txt", True

Creating the export spec is easy but convoluted to find.
You have to manually export the table, choose the csv type and then the Advanced button to define and name the export spec.
Only Microsoft know why it is placed out of the way there!

Peter
 

Users who are viewing this thread

Back
Top Bottom