PC Review


Reply
Thread Tools Rate Thread

bulk copy to Excel

 
 
Ben
Guest
Posts: n/a
 
      21st May 2010
Hi all,

I have Access and Excel 2003. I have a query that returns about 3K
rows. When the query returns the records, I can do a bulk copy by right
clicking on the upper left corner and select copy and just paste the
entire recordset onto Excel. Is there a way to do that in code rather
than writing out each record field-by-field? There's about 50 fields and
it takes way too long. Please show me a code snippet to accomplish this
task. Thanks in advance for sharing your thoughts.


Ben
 
Reply With Quote
 
 
 
 
Douglas J. Steele
Guest
Posts: n/a
 
      21st May 2010
Look at the TransferSpreadsheet method. You can specify the query name
rather than a table name.

--
Doug Steele, Microsoft Access MVP
http://www.AccessMVP.com/DJSteele
(no e-mails, please!)

"Ben" <(E-Mail Removed)> wrote in message
news:eh58x8P%(E-Mail Removed)...
> Hi all,
>
> I have Access and Excel 2003. I have a query that returns about 3K rows.
> When the query returns the records, I can do a bulk copy by right clicking
> on the upper left corner and select copy and just paste the entire
> recordset onto Excel. Is there a way to do that in code rather than
> writing out each record field-by-field? There's about 50 fields and it
> takes way too long. Please show me a code snippet to accomplish this
> task. Thanks in advance for sharing your thoughts.
>
>
> Ben



 
Reply With Quote
 
ryguy7272
Guest
Posts: n/a
 
      21st May 2010
This is a GREAT resource:
http://www.accessmvp.com/KDSnell/EXCEL_Export.htm

These two are probably most relevant to your post:
http://www.accessmvp.com/KDSnell/EXC...ExportSepFiles
http://www.accessmvp.com/KDSnell/EXC...ExportSameFile

--
Ryan---
If this information was helpful, please indicate this by clicking ''Yes''.


"Douglas J. Steele" wrote:

> Look at the TransferSpreadsheet method. You can specify the query name
> rather than a table name.
>
> --
> Doug Steele, Microsoft Access MVP
> http://www.AccessMVP.com/DJSteele
> (no e-mails, please!)
>
> "Ben" <(E-Mail Removed)> wrote in message
> news:eh58x8P%(E-Mail Removed)...
> > Hi all,
> >
> > I have Access and Excel 2003. I have a query that returns about 3K rows.
> > When the query returns the records, I can do a bulk copy by right clicking
> > on the upper left corner and select copy and just paste the entire
> > recordset onto Excel. Is there a way to do that in code rather than
> > writing out each record field-by-field? There's about 50 fields and it
> > takes way too long. Please show me a code snippet to accomplish this
> > task. Thanks in advance for sharing your thoughts.
> >
> >
> > Ben

>
>
> .
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Bulk Copy Fail ad Microsoft ADO .NET 2 15th Nov 2006 07:26 PM
How to copy bulk copy MS Access queries from one database to another Ron Carr Microsoft Access Queries 4 27th Dec 2005 05:25 PM
ADO.net, asp.net & Bulk Copy Francis Microsoft ADO .NET 3 16th May 2005 02:40 PM
Bulk Copy from datasource A to B Cip Microsoft ADO .NET 4 13th Apr 2004 02:29 PM
Bulk Copy Oleg Microsoft ADO .NET 2 17th Dec 2003 03:59 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:57 AM.