Logo 
Search:

MS Office Answers

Ask Question   UnAnswered
Home » Forum » MS Office       RSS Feeds
  Question Asked By: Hope Duncan   on Nov 12 In MS Office Category.

  
Question Answered By: Stefan Thompson   on Nov 12

Sounds as thought the key thing is to loop through a set of worksheets.

The following code will do that.

Sub subLoopThroughSheets()
' Loop through a woorkbook.

Dim slSheetName As String
Dim olSheet As Worksheet

For Each olSheet In Worksheets
slSheetName = UCase(olSheet.Name)
olSheet.Activate

Select Case slSheetName

' Do NOT "process" at these sheets.
Case "A", "B", "C"
' Do nothing.

Case Else
' Collect data... maybe put it in an array.

End Select
Next olSheet

' Go to the worksheet you want the summary  in and process the array.

MsgBox "Done."

End Sub

Share: 

 
 
Didn't find what you were looking for? Find more on VB function Or get search suggestion and latest updates.


Tagged: