Can I create a table 'on the fly' to host an xl import?
I'm using...
DoCmd.TransferSpreadsheet acImport, 8, "tbl_Import", sPathOfFileToImport, True
...at the moment, and it would be neat if I could tie it into that statement
The issue is that I need to import an xl spreadsheet whose column headers (some of them, anyway) change on a weekly basis. I tried changing the 'True' (hasColumnHeadings) to False, but I get an error telling me field F1 does not exist in the target table.
I thought maybe it'd easier to import the spreadsheet and create the table on the fly - but I would welcome a better suggestion.
Thanks in advance
Hoz
I'm using...
DoCmd.TransferSpreadsheet acImport, 8, "tbl_Import", sPathOfFileToImport, True
...at the moment, and it would be neat if I could tie it into that statement
The issue is that I need to import an xl spreadsheet whose column headers (some of them, anyway) change on a weekly basis. I tried changing the 'True' (hasColumnHeadings) to False, but I get an error telling me field F1 does not exist in the target table.
I thought maybe it'd easier to import the spreadsheet and create the table on the fly - but I would welcome a better suggestion.
Thanks in advance
Hoz