I have a DB with multiple tables that have the data imported into them from Excel spreadsheets.
I would like to have a Macro available to mimic the "Select Source and Destination of the Data" popup
that results when one hits the Excel button under the External Data Section.
I have not written any vba code before. I know that the resultant vba from using the ImportExcelSpreadsheet option is shown below.
So What I really need to do is to replace the "","" with calls to subroutine that request the Table Name of the table to import into, and the File Name to import from. Any help would be appreciated. Thanks, Arnie
Function Macro1()
On Error GoTo Macro1_Err
DoCmd.TransferSpreadsheet acImport, 10, "", "", True, ""
Macro1_Exit:
Exit Function
Macro1_Err:
MsgBox Error$
Resume Macro1_Exit
End Function