Last Row Help

  • Thread starter Thread starter Michael168
  • Start date Start date
M

Michael168

Can someone modify the macro below so that it will always copy the las
row and paste one row below when I run the macro.
The macro runs from sheet 1 - sheet 10

Sub Macro1()
'
' Macro1 Macro
' Macro recorded 6/8/2004 by Michael
'

'
Sheets("Sheet 1").Select
Range("A240").Select
Range(Selection, ActiveCell.SpecialCells(xlLastCell)).Select
Selection.Copy
Range("A241").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Sheets("Sheet 2").Select
Range("A240").Select
Range(Selection, ActiveCell.SpecialCells(xlLastCell)).Select
Selection.Copy
Range("A241").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A242").Select

.............. until Sheet 10

End Sub

Thanks
Michae
 
One way:

Public Sub CopyToNextRow()
Dim i As Long
For i = 1 To 10
With Worksheets(i)
With .Range("A" & .Rows.Count).End(xlUp)
.EntireRow.Copy .Offset(1, 0)
End With
End With
Next i
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top