chadski778
Active Member
- Joined
- Mar 14, 2010
- Messages
- 297
I would like a macro for copying the contents of an active cell and pasting into 100 cells immediately below the active cell in the same column, if that is possible?
Sorry I meant pasting into every cell up to the last occupied row of the Active cell column
Sub CopyDown()
Dim myRow As Integer
Dim LastRow As Integer
Dim NewRows As Integer
myRow = ActiveCell.Row
LastRow = ActiveCell.End(xlDown).Row
NewRows = (LastRow - myRow) + 1
ActiveCell.Resize(NewRows, 1).Value = ActiveCell.Value
End Sub
Sub CopyDown()
Dim myRow As Integer
Dim LastRow As Integer
Dim NewRows As Integer
myRow = ActiveCell.Row
LastRow = ActiveSheet.Cells(65536, ActiveCell.Column).End(xlUp).Row
NewRows = (LastRow - myRow) + 1
ActiveCell.Resize(NewRows, 1).Value = ActiveCell.Value
End Sub
Sub CopyDown()
Dim myRow As Integer
Dim LastRow As Integer
Dim NewRows As Integer
myRow = ActiveCell.Row
LastRow = Cells.Find("*", SearchOrder:=xlByRows, SearchDirection:=xlPrevious).Row
NewRows = (LastRow - myRow) + 1
ActiveCell.Resize(NewRows, 1).Value = ActiveCell.Value
End Sub