LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 259
Default Cycling through collection

Hi all

Was hoping someone could help me with the correct layout for cycling
through a collection of sheets which are exactly the same, all 12.

They represent one sheet for each month in the year and are structured
in the following:

A5:J1500

The range from each sheet needs to be copied to the summary sheet.

Kinda something like:

Dim Wkb as Workbook
Dim Wks as Worksheet
Dim Rng as Range
Dim TS as Worksheet

Set rng = ("A5:J1500")
Set TS = Sheets("Summary")
Set wks = ("Jan", "Feb", "Mar"....."Dec")

For each Wks in Wkb
Rng.copy(<"", SpecialCells(Rows.xlUp), Not xlFormulas

TS.Activate

Columns("A").Find("", Cells(Rows.Count, "A"), xlValues, _
xlWhole, , xlNext).Select

Selection.PasteSpecial Paste:=xlPasteValues,Operation:=xlNone,SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False


'Do my other stuff

TIA
Mick.













 
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
How can I check a collection (e.g. worksheets) collection to be empty? Michiel via OfficeKB.com Excel Programming 2 March 25th 10 02:22 PM
Tab keeps cycling through the same row Mike Excel Discussion (Misc queries) 2 August 14th 08 12:20 AM
Not cycling through each sheet Michael Smith Excel Programming 4 January 20th 06 07:46 PM
cycling through columns? Kirk Excel Programming 2 May 2nd 05 07:51 PM
Cycling through worksheets Chris Gorham[_3_] Excel Programming 2 November 5th 03 08:37 PM


All times are GMT +1. The time now is 09:02 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"