Jamie Harris
New Member
- Joined
- Feb 26, 2017
- Messages
- 4
Sub Copy_Month()
Application.ScreenUpdating = False
Dim i As Long
Dim Lastrow As Long
Dim Lastrowa As Long
Sheets("2017").Activate
Lastrow = Sheets("2017").Cells(Rows.Count, "R").End(xlUp).Row
Lastrowa = Sheets("January").Cells(Rows.Count, "R").End(xlUp).Row
For i = 1 To Lastrow
If Cells(i, "R").Value = "January" Then
Rows(i).Copy Destination:=Sheets("January").Rows(Lastrowa)
Lastrowa = Lastrowa + 1
End If
Next
Application.ScreenUpdating = True
End Sub
is there anyway of using a formula??
I know of no formula that can copy entire rows of data to other sheets based on a value in a cell.
Okay with the macro you have gave it works but it doesn't update when there is a new January job add to the 2017 sheet?