When I try to import data from an Excel file into an Access database using the below code I do get a table "test" created okay but it only has a single empty column in it with a field name F1 assigned to it. I couldn't get all the defined fields from the Excel file with data into test table to reside in Access file.
Private Sub Command0_Click()
Dim Filepath As String
Filepath = "C:\Users\ErdenR\Desktop\Local Data Warehouse\Exports\OCEAN\201801_OCEAN_MTD.xlsb"
DoCmd.TransferSpreadsheet acImport, , "test", Filepath, True
Can any expert help with that issue please?