Solved

Importing xlsx into Access 2007

Posted on 2013-05-21
3
703 Views
Last Modified: 2013-09-12
Hi,
I am trying to import an xlsx file into access but seem to be having some difficulty.
The code i am using is:
  ' Import into Access:
  DoCmd.TransferSpreadsheet acImport, _
   acSpreadsheetTypeExcel97, strcTableName, _
   strFullPath, True

I think the error is with "acSpreadsheetTypeExcel97" but i am not sure.
Any Ideas?

Kind Regards,
Andrew
0
Comment
Question by:andrew_optimum
  • 2
3 Comments
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 500 total points
ID: 39184488
change this

 DoCmd.TransferSpreadsheet acImport, _
   acSpreadsheetTypeExcel97, strcTableName, _
   strFullPath, True


with


 DoCmd.TransferSpreadsheet acImport, _
   10, strcTableName, _
   strFullPath, True

or

 DoCmd.TransferSpreadsheet acImport, _
   acSpreadsheetTypeExcel12xlm, strcTableName, _
   strFullPath, True
0
 

Author Comment

by:andrew_optimum
ID: 39184509
DoCmd.TransferSpreadsheet acImport, _
   10, strcTableName, _
   strFullPath, True

This gives me the following error: External table is not in the expected format.

 DoCmd.TransferSpreadsheet acImport, _
   acSpreadsheetTypeExcel12xlm, strcTableName, _
   strFullPath, True

This gives me the following error: Could not find installable ISAM.
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 39184679
upload a copy of the excel file..
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question