How to assure a "TransferSpreadsheet" import goes to desired Table

  • Thread starter EagleOne@microsoftdiscussiongroups
  • Start date
E

EagleOne@microsoftdiscussiongroups

2003

VBA Macro in Database Tools.mdb creates Reconcile.mdb then
imports two tables: 1) a "Text" import; 2) an Excel file import

For the text import, I use: ( and it works fine with a Schema.ini file)
dbs.Execute "SELECT * INTO STARSData FROM _
[Text;FMT=Fixed;HDR=No;DATABASE=" & myPath _
& ";].[STARSData#txt];", dbFailOnError

For the Excel import, I use (it works but places the data in the wrong table):
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel8, _
strTableName, "C:\Reconciliations\myData.xls", True

What VBA code can I use to force the data into dbs (Reconcile.mdb) and not
into Tools.mdb where it is now going?

TIA EagleOne
 

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