Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Importing / Linking / July 2005

Tip: Looking for answers? Try searching our database.

Importing Multiple Excel Files

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
TOMB - 07 Jul 2005 16:40 GMT
I have several excel files (100+) with data I need to import into Access.

Each excel file has multiple sheets (4 to 6 sheets). I need to import data
from each sheet.
No blank sheets are included, and all sheets are formated the same.

Thanks in advance for any assistance.

TB
Klatuu - 07 Jul 2005 17:08 GMT
Look in Access Help for the FileSearch object.  You can use it to get an
array of the Excel files you want to import.  You can then use the
TransferSpreadsheet method to import data from the files.  The tricky part
will be knowing which sheets you want to import.  You may have to create an
Excel object to open each file and get the count of sheets in the file so you
know how many TransferSpreadsheet calls you need to do for the sheet:

Do a FileSearch to get an array of Excel files to import.
Do a Loop through all the files in the array
   Open the file
   Get a count of sheets in the file
   Close the file
   Do a Loop through the sheets
       Do a TransferSpreadsheet for a sheet
   End of Loop through sheets
End of Loop through files

> I have several excel files (100+) with data I need to import into Access.
>
[quoted text clipped - 5 lines]
>
> TB
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.