Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default Record Set To Sheet

I am wondering the easy way to take data retrieved from a database, which is
now sitting in a record set, and place that data into the sheet. Do I need
to itterate through the record set and navigate cell by cell of my sheet, or
is there a quicker way to get all the data loaded into a specific area of my
sheet

Thanks in advance for your assistance!!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 694
Default Record Set To Sheet

Hi

Use the CopyFromRecorset method of the Range object.
Say you want to paste your recordset starting in A1:
Dim Rst as adodb.recordset
...
Range("A1").CopyFromRecordset Rst

done!
The syntax is Range.CopyFromRecorset Recordset, MaxRows, MaxColumns
--
Regards,
Sébastien
<http://www.ondemandanalysis.com


"Jim Heavey" wrote:

I am wondering the easy way to take data retrieved from a database, which is
now sitting in a record set, and place that data into the sheet. Do I need
to itterate through the record set and navigate cell by cell of my sheet, or
is there a quicker way to get all the data loaded into a specific area of my
sheet

Thanks in advance for your assistance!!

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Duplicate sheet, autonumber sheet, record data on another sheet des-sa[_2_] Excel Worksheet Functions 0 May 8th 08 06:56 PM
How to record a sheet change showing row column sheet name and date? Simon Lloyd[_584_] Excel Programming 0 October 6th 04 12:57 PM
How to record a sheet change showing row column sheet name and date? Simon Lloyd[_583_] Excel Programming 0 October 6th 04 10:32 AM
How to record a sheet change showing row column sheet name and date? Simon Lloyd[_578_] Excel Programming 0 October 5th 04 12:06 PM
How to record a sheet change showing row column sheet name and date? Simon Lloyd[_574_] Excel Programming 1 October 5th 04 11:22 AM


All times are GMT +1. The time now is 06:55 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"