Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Help Inserting data into a range of cells

Hi, I'm trying to use Excel 2000 VBA with ADO.

I have a ADO recordset that i would like to insert into a range on a
worksheet. Each row in my recordset exactly matches the columns.

I know i loop through my recordset and insert my values 1 cell at a
time for each record, but this seems extremely slow especially when
1000s of records come back from my database call.

I would like know if there is some way to add/paste my entire 1500 rows
from my recordset into a range in one go?

Am i just chasing a pipe dream here or is this possible using VBA?


-Thanks, -


---
Message posted from http://www.ExcelForum.com/

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,080
Default Help Inserting data into a range of cells

The CopyFromRecordset method should do this for you.

--

Vasant



"StuckInTheMiddl " wrote in
message ...
Hi, I'm trying to use Excel 2000 VBA with ADO.

I have a ADO recordset that i would like to insert into a range on a
worksheet. Each row in my recordset exactly matches the columns.

I know i loop through my recordset and insert my values 1 cell at a
time for each record, but this seems extremely slow especially when
1000s of records come back from my database call.

I would like know if there is some way to add/paste my entire 1500 rows
from my recordset into a range in one go?

Am i just chasing a pipe dream here or is this possible using VBA?


-Thanks, -


---
Message posted from http://www.ExcelForum.com/



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
Inserting data into Word document by a range of dates from Excel spreadsheet Gordon[_6_] New Users to Excel 3 July 29th 08 08:22 PM
Inserting a range of cells Shazzer Excel Worksheet Functions 1 July 4th 07 06:53 PM
Inserting data between cells Smoop Excel Worksheet Functions 1 October 18th 06 07:07 PM
Inserting iserror into a range of cells Shatin Excel Programming 1 February 8th 04 08:27 AM
Inserting data in cells bt707[_3_] Excel Programming 2 October 9th 03 02:22 AM


All times are GMT +1. The time now is 06:26 AM.

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"