
Originally Posted by
Ajax
per my suggestion
ok I got some time to try out your suggestion but the problem is how do I import the excel contents to a temporary table? I have the below code in vba which imports the data at the click of a button:
Code:
Sub Macro_Import_Reservation_Report()
On Error GoTo Macro_Import_Err
DoCmd.TransferSpreadsheet acImport, 10, "TheTable", "C:\Excel Report", True, ""
Macro_Import_Exit:
Exit Sub
Macro_Import_Err:
MsgBox Error$
Resume Macro_Import_Exit
End Sub
"TheTable" is a predefined table in access. How do I modify the code such that it imports to a new temporary table?