R
rbm
I am importing an Excel spreadsheet Named Range into an
existing Access 97 table using the TransferSpreadsheet
Action. I had my share of weird problems, but I seem to
have got to the point where everything will import
correctly. BUT this only works when the Excel file is
open. If I close Excel (or just the worksheet), it won't
import at all - I get a "Numeric Field Overflow" error.
It I open the spreadsheet and then go back to Access and
run the procdure again, I get no error and the data
imports.
This is the code I am using:
DoCmd.TransferSpreadsheet acImport,
acSpreadsheetTypeExcel97, "tblRegistration", varFileName,
True, "Registration"
"varFileName" is the name of the file containing the data
to import (C:\Program Files\Access\Register.xls")
"Registration" is the Named Range in the spreadsheet
It doesn't seem right that I should have to have the file
open in order to import data.
existing Access 97 table using the TransferSpreadsheet
Action. I had my share of weird problems, but I seem to
have got to the point where everything will import
correctly. BUT this only works when the Excel file is
open. If I close Excel (or just the worksheet), it won't
import at all - I get a "Numeric Field Overflow" error.
It I open the spreadsheet and then go back to Access and
run the procdure again, I get no error and the data
imports.
This is the code I am using:
DoCmd.TransferSpreadsheet acImport,
acSpreadsheetTypeExcel97, "tblRegistration", varFileName,
True, "Registration"
"varFileName" is the name of the file containing the data
to import (C:\Program Files\Access\Register.xls")
"Registration" is the Named Range in the spreadsheet
It doesn't seem right that I should have to have the file
open in order to import data.