Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Copy ata from several workbooks and paste into new work book

Hi All,

I am trying to copy a range of data from a series of opened workbooks
and paste them into a new workbook? How can I do this? So far, I've
figured out how to copy the range I want from one notebook, but that's
all. Here is my code for this:

Sub Macro1()
Range("A6", Range("A6").End(xlDown).End(xlToRight)).Select
Selection.Copy
End Sub

Thanks in advanced for any help.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Copy ata from several workbooks and paste into new work book

mchangun,
Record a macro whilst performing the desired actions.
Edit the code as necessary.

NickHK

wrote in message
ups.com...
Hi All,

I am trying to copy a range of data from a series of opened workbooks
and paste them into a new workbook? How can I do this? So far, I've
figured out how to copy the range I want from one notebook, but that's
all. Here is my code for this:

Sub Macro1()
Range("A6", Range("A6").End(xlDown).End(xlToRight)).Select
Selection.Copy
End Sub

Thanks in advanced for any help.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Copy ata from several workbooks and paste into new work book

Recording a marco helps with the paste part of the code, but doesn't
help me with looping through the opened workbooks.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Copy ata from several workbooks and paste into new work book

mchangun,
Dim WB as Workbook

For each WB in workbooks
...code
Next

NickHK

wrote in message
ups.com...
Recording a marco helps with the paste part of the code, but doesn't
help me with looping through the opened workbooks.



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
Can't Copy and Paste or Paste Special between Excel Workbooks wllee Excel Discussion (Misc queries) 5 April 29th 23 03:43 AM
how do i copy a worksheet to another work book multi work book sheet copies Excel Worksheet Functions 1 July 15th 08 08:38 PM
automate a cut and paste of data from one work book to another Ian Anderson Excel Discussion (Misc queries) 2 May 30th 06 07:59 PM
I wish automate a cut and paste of data from one work book to ano Ian Anderson Excel Worksheet Functions 2 May 28th 06 08:28 AM
Macro, Persoanl Work book and CSV workbooks James Agostinho Excel Programming 2 February 13th 04 03:43 AM


All times are GMT +1. The time now is 02:51 AM.

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

About Us

"It's about Microsoft Excel"