xl table with two unwanted leading lines

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to import an xl file to my db system, but i am having couple of
problems.
1. the file has two lines that i dont want and when i try to import into an
existing table, the wizard doesnt let me.
2. dont really want to be going back to the xl file and deleting the
unwanted lines and just link the xl as a table in my DB....

do anyone has any item on how can i solve this...thanks
 
Hi Will,

If you know the number of columns and approximate number of rows, you
can specify the part of the worksheet you want to import using the Range
argument of TransferSpreadsheet. E.g. this

DoCmd.TransferSpreadsheet acImport, , "BBID", _
"C:\Temp\AB1.xls", True, "BBID$A3:G20"

has just worked in my test database to import up to 17 rows of 7 columns
from worksheet BBID in workbook AB1.xls, starting at cell A3.
 
works like a charm, thanks
--
need help


John Nurick said:
Hi Will,

If you know the number of columns and approximate number of rows, you
can specify the part of the worksheet you want to import using the Range
argument of TransferSpreadsheet. E.g. this

DoCmd.TransferSpreadsheet acImport, , "BBID", _
"C:\Temp\AB1.xls", True, "BBID$A3:G20"

has just worked in my test database to import up to 17 rows of 7 columns
from worksheet BBID in workbook AB1.xls, starting at cell A3.
 
Back
Top