I am looking for a code to import and existing excel file into and existing Access table.
I cannot use TransferSpreadsheet as the field names do not match and I cannot change the excel file to match access (or vice versa).
Tried TransferText but could not create a specification for it as the file is excel not tet.
Searched and found the following that I have been trying to use:
Dim oExcel as New Excel.Application
Dim oSheet as Excel.Worksheet
oExcel.WorkBooks.Open "xxxx.xls"
Set oSheet = oExcel.ActiveWorkbook.Worksheets("SheetName")
It then say to use Cells to proress but offers ot more info.
Can someone help!
I need to continue the above to then select a range of cells
A1
100 to then populate the table.
I cannot use TransferSpreadsheet as the field names do not match and I cannot change the excel file to match access (or vice versa).
Tried TransferText but could not create a specification for it as the file is excel not tet.
Searched and found the following that I have been trying to use:
Dim oExcel as New Excel.Application
Dim oSheet as Excel.Worksheet
oExcel.WorkBooks.Open "xxxx.xls"
Set oSheet = oExcel.ActiveWorkbook.Worksheets("SheetName")
It then say to use Cells to proress but offers ot more info.
Can someone help!
I need to continue the above to then select a range of cells
A1