T
Tore
The user has moved from office 2003 to office 2007. The access adp solution
is developed in access 2003 and works perfectly in with office 2007 except
for some details.
How can I export more than 65536 records from access adp client to excel 2007?
Here is a part of the current VBA code:
RS is an adodb.recordset containing the records to be exported.
ExcelRange.CopyFromRecordset RS cannot take more than 65536 records?
' Create an instance of Excel and add a workbook
Set xlApp = CreateObject("Excel.Application")
Set xlWb = xlApp.Workbooks.Add
Set xlWs = xlWb.Worksheets.Item(1)
' Display Excel and give user control of Excel's lifetime
xlApp.Visible = True
xlApp.UserControl = True
' Copy field names to the first row of the worksheet
fldCount = RS.Fields.Count
For iCol = 1 To fldCount
xlWs.Cells(1, iCol).Value = RS.Fields(iCol - 1).Name
Next
xlWs.Cells(2, 1).CopyFromRecordset RS
is developed in access 2003 and works perfectly in with office 2007 except
for some details.
How can I export more than 65536 records from access adp client to excel 2007?
Here is a part of the current VBA code:
RS is an adodb.recordset containing the records to be exported.
ExcelRange.CopyFromRecordset RS cannot take more than 65536 records?
' Create an instance of Excel and add a workbook
Set xlApp = CreateObject("Excel.Application")
Set xlWb = xlApp.Workbooks.Add
Set xlWs = xlWb.Worksheets.Item(1)
' Display Excel and give user control of Excel's lifetime
xlApp.Visible = True
xlApp.UserControl = True
' Copy field names to the first row of the worksheet
fldCount = RS.Fields.Count
For iCol = 1 To fldCount
xlWs.Cells(1, iCol).Value = RS.Fields(iCol - 1).Name
Next
xlWs.Cells(2, 1).CopyFromRecordset RS