this is also a different approach i have tried:
Code:
Dim db As dao.Database, rs As dao.Recordset
Dim xlApp As Excel.Application
Dim xlFile As Excel.Workbook
Dim xlSheet As Excel.Worksheet
Dim xlRange As Excel.Range
Dim r#, c#
Dim strPath As String, strFile As String, strTable As String
Set xlApp = New Excel.Application
strPath = "T:\XL Files\"
strFile = "ASCII-Codes2.xlsx"
Set xlFile = xlApp.Workbooks.Open(strPath & strFile)
Set xlSheet = xlFile.Sheets("Sheet1")
Set xlRange = xlSheet.Range("A1:C256")
For r = 1 To xlRange.Rows.Count
For c = 1 To xlRange.Columns.Count
Set db = CurrentDb()
Set rs = db.OpenRecordset("Select * From tblAscllCodes")
With rs
.AddNew
!Code = c
.Update
.Close
End With
Next c
Next r
xlApp.Quit
Set xlApp = Nothing