Dont Understand!! I Tried!!!

DaniBoy

Registered User.
Local time
Today, 18:14
Joined
Nov 18, 2001
Messages
174
Hello
I am trying to make my file to be imported from an exel spreadsheet automaticly from a push of a botton. I have read on the forum and I have part of it done, but I dont understand the error I get, it says to specify a name argument. Well I looked in a couple of posts and I can see the that some put "APS_Import" I tried but didnt work, I also looked at the help files in access but I just don understand what they mean. Pleas help me.

here is the code

DoCmd.TransferText acImportFixed, "APS_Import", "WorkOrders", "C:\WorkOrders.xls"


Thanks

DaniBoy
 
The TransferText method is for importing and exporting text files.

You might want to use TransferSpreadsheet instead.

See Access help under TransferSpreadsheet for more information.

Hope this helps,
 
You are using the TransferText method whereas since it's an Excel file you want to import you should be using the TransferSpreadsheet method. Try the following:

DoCmd.Transferspreadsheet acImport, 8, "WorkOrders", "C:\WorkOrders.xls"

Check the help file for TransferSpreadsheet for full details
 
Thank you guys!!!

I dont know how I missed that, anyway its friday!!!:)
I will try it out

Thanks

DaniBoy
 

Users who are viewing this thread

Back
Top Bottom