Connecting to excel via Access query

  • Thread starter Thread starter John Acocella
  • Start date Start date
J

John Acocella

I am aware that you can use the Source Database property
of a query to use a table in an external Access database.
Is there a way to use this property to connect to an Excel
spreadsheet. Trying to avoid creating a table link to
access the Excel data. Thanks.
 
Use File, Get External Data, to create a link to the
Excel spread sheet, then in the immediate window in
the vba project, type (and press [enter])

?codedb.tabledefs("myexceltbl").connect

to get a sample of the kind of database name and
table name you need to use, to select data from
an excel spreadsheet.

(david)
 
Back
Top