Home Forums Article Discussions Article Discussions by Author Discuss Content Posted by Roy Carlson Scripted Server Snapshot RE: Scripted Server Snapshot
RobertPaquette
Old Hand
Points: 307
More actions
July 12, 2005 at 7:20 am
#573330
I called objRecordSet rs and objWorksheet ws,
but it seems like you could just do something like this
For CurCol = 0 To rs.Fields.Count - 1: ws.Cells(1, CurCol + 1).Value = rs.Fields(CurCol).Name: Next
ws.Range("A2").CopyFromRecordset rs