Import from a specific Worksheet

  • Thread starter Thread starter MichaelK
  • Start date Start date
M

MichaelK

To import from the specific Excel worksheet I use:

DoCmd.TransferSpreadsheet acImport, , "zzz", xlsFile, True,
"SomeName!A1:R1000"

Usually there are less then 1000 records, but you never know, just want to
be safe.
What format would be to import all records from colums A thru R,
or just from the specific worksheet regardless of the range.

Thanks,
Michael
 
I would suggest naming the range in your spreadsheet and referring to it by
that name

"SomeName!SomeRange"

Please let me know if I can provide more assistance.
 
Just remove the row numbers.

DoCmd.TransferSpreadsheet acImport, , "zzz", xlsFile, True,
"SomeName!A:R"
 
Back
Top