R
rirus
I have several Excel Spreadsheets linked in an Access DB that I want to
combine into one table. All colunmn headers are identical in the Worksheets.
Manually, I can create a Make Table Query on the first linked spreadsheet,
selecting all fields. This creates the New Table. All other spreadhseets I
use an Append to Table Query. I have to do this each month for reporting
purposes. Since the table is for one months worth of data, to eleviate
confusion I create a new table each month.
Question:
I am wondering if there is a way I could do this with VBA? Since all the
header fields are the same in the spreadsheets I could use the select *
statement in the query and then change the table names accordingly.
I think all I need is the basic CreateTableQuery and AppendQueryQuery VBA
code. My understanding of VBA code is ok... I am no expert. Any help would be
appreciated.
thanks,
Rirus
combine into one table. All colunmn headers are identical in the Worksheets.
Manually, I can create a Make Table Query on the first linked spreadsheet,
selecting all fields. This creates the New Table. All other spreadhseets I
use an Append to Table Query. I have to do this each month for reporting
purposes. Since the table is for one months worth of data, to eleviate
confusion I create a new table each month.
Question:
I am wondering if there is a way I could do this with VBA? Since all the
header fields are the same in the spreadsheets I could use the select *
statement in the query and then change the table names accordingly.
I think all I need is the basic CreateTableQuery and AppendQueryQuery VBA
code. My understanding of VBA code is ok... I am no expert. Any help would be
appreciated.
thanks,
Rirus