Importing to Access from Excel using DoCmd.TransferSpreadsheet

LeeSmith

Registered User.
Local time
Today, 17:00
Joined
Mar 17, 2006
Messages
27
Hello

I am currently trying to get a spreadsheet to import into an access table at the click of a button. The code I am currently using is below

DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel8, "Details", "filepath\LearnerSupportCollegeProvision.xls", True, " "

I have tried this and a few variations with no success. The most common error is "Unexpected Error from External Database (22)

Can anyone suggest a solution to this?

Many thanks
 
check the sample on this either Boblarson or Ghudson have done a sample d/b that does this

g
 
Apologies for my n00bness, but what would be the easiet way to find them?
 
type in "Ghudson" in the search and then look for attchments -
its a sample d/b with about 5 fuctions in it
 

Users who are viewing this thread

Back
Top Bottom