I found the code below and it works perfectly if I want to copy all the other sheets to a master sheet. But, I need to specify specific sheets. Basically I have a workbook consisting of multiple sheets and multiple "master" sheets so I need to specify in the code which sheets it should be copying.
Private Sub Worksheet_Activate()
Dim Sheet As Worksheet
For Each Sheet In Me.Parent.Sheets
If Sheet.Name <> Me.Name Then
If Sheet.Cells(Rows.Count, 1).End(xlUp).Row <> 1 Then
Sheet.Range(Sheet.Cells(2, 1), Sheet.Cells(Sheet.Cells(Rows.Count, 1).End(xlUp).Row, 18)).Copy Destination:=Me.Cells(Rows.Count, 1).End(xlUp).Offset(1, 0)
End If
Else
Me.Range(Cells(2, 1), Cells(Rows.Count, 18)).Clear
End If
Next Sheet
End Sub
I have found this question asked before but never ran across any useful answers. I am an extreme rookie when it comes to VBA.
Any advise would be greatly appreciated.
Bookmarks