Unanswered: Import Excel Spreadsheet Ranges into a table
Hi, I am trying to import a series of Ranges from a spreadsheet into different tables within access. I have written some code that would import a worksheet into a table but I want to adapt it so that it will pick up the different ranges and import to relevant tables.
I have 5 ranges that need to be imported to 5 tables.
Private Sub cmdImport_Click()
strPath = "\\titan\home\jeremyl1\"
strFileName = Dir(strPath & "5HG_Feb_Comm.xls")
MsgBox "Data Loading...", vbInformation, "Jez"
If Len(strFileName) <> 0 Then
DoCmd.TransferSpreadsheet acImport, , strTempTable, strPath &
MsgBox "Import Complete", vbInformation, "Jez"