Hi guys,
I have this little piece of code which some of you kindly helped me with a few weeks back. As you can see it copies a range from several sheets and pastes it into another called Printout. However, some of the cells contain formulas which are messing up. Is it possible to change the code to reflect a paste special (values) rather than a straight copy? Here is the code...
***************************************************************
Private Sub PrintHC_Click()
Dim i As Long
i = 2
Worksheets("Printout").Select
For Each sh In Worksheets
If sh.Name <> "Begin" And sh.Name <> "Index" And sh.Name <> "Codes" And sh.Name <> "Printout" Then
sh.Range("A2:M12").Copy Worksheets("Printout").Range("A" & i)
i = Worksheets("Printout").Cells(Rows.Count, 1).End(xlUp).Row + 2
End If
Next sh
End Sub
*********************************************************
Many Thanks
Jose
I have this little piece of code which some of you kindly helped me with a few weeks back. As you can see it copies a range from several sheets and pastes it into another called Printout. However, some of the cells contain formulas which are messing up. Is it possible to change the code to reflect a paste special (values) rather than a straight copy? Here is the code...
***************************************************************
Private Sub PrintHC_Click()
Dim i As Long
i = 2
Worksheets("Printout").Select
For Each sh In Worksheets
If sh.Name <> "Begin" And sh.Name <> "Index" And sh.Name <> "Codes" And sh.Name <> "Printout" Then
sh.Range("A2:M12").Copy Worksheets("Printout").Range("A" & i)
i = Worksheets("Printout").Cells(Rows.Count, 1).End(xlUp).Row + 2
End If
Next sh
End Sub
*********************************************************
Many Thanks
Jose