View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Kirk P. Kirk P. is offline
external usenet poster
 
Posts: 66
Default ADO Recordset include Field names

How do I modify this code to get the Field names from rec6 to start in column
13? They currently start in column 1, and I've tried modifying it several
ways - so far no luck.

For nCol = 1 To rec6.Fields.Count
Sheets("ACN").Cells(7, nCol).Value = rec6.Fields(nCol - 1).Name
Next nCol
Sheets("ACN").Cells(8, 13).CopyFromRecordset rec6

Thanks!