I tried the code with automation:
For Each sheet In objWorkBook.sheets 'for each sheet in excel loop
Debug.Print "Imported sheet is :"; sheet.Name
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel9, sheet.Name, "OperatorData", True, sheet.Name & "!"
Next
the OPERATORDATA excel file has 10 work sheets.
after importing 6 sheets, this run time error is displayed indicating DOCMD.TransferSpreadSheet line
I tried to import through GetExternalData/Import from Access File Menu.
this displays an error message without help button on the message box and the message reads like.... SUBSCRIPT OUT OF RANGE.
Can any one help me please.
With regards
Repath.