TransferSpreadsheet Link method with .csv problem

V

Vantastic

I'm having an issue linking to an external .csv file. The code used is typical:

DoCmd.TransferSpreadsheet acLink, , "Ariba_Link", stFullpathCSV,
True, "A6:AB50000"

As you can see there is a tonne of information to look at so I don't want to
Import it as this linking will need to occur daily. (Code before that simply
checks to see if today's file exists and if so proceeds to delete the old
table link and create a new one)

The problem is that when I have said .csv file open in Excel, the linking
works fine. When the file is not open, i get an error saying that the file is
in an unexpected format.

Has anyone else encountered this problem before and found a work-around?
This process needs to be absolutely automated with no user involvement
required, as in changing the format to excel first. I've tried importing the
csv file, then exporting, then linking to it, which works, but if this
happens every time a user (on a multi-user environment) opens it up then they
will get write-access errors. Don't want that ;)

TIA

Niko
 
V

Vantastic

I found the solution with the TransferText method

*slaps forehead*

Sorry to have wasted your time.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top