ivanka2000
New Member
Hello
Can you please help me to change the macro that it copy from Planning sheet to complete sheet not only values but also formats (cell colours) based on the criterion?
Thank you
Mod Edit: Code tags added
Can you please help me to change the macro that it copy from Planning sheet to complete sheet not only values but also formats (cell colours) based on the criterion?
Thank you
Code:
Sub MoveComplete()
colnum = 100 'enter number of columns to be copied to sheet complete
l1 = Sheets("Planning_2016").Range("A" & Rows.Count).End(xlUp).Row
For n = 5 To l1
k = l1 - n + 5
If UCase(Sheets("Planning_2016").Range("I" & k).Value) = UCase("completed") Then
l2 = Sheets("Complete").Range("A" & Rows.Count).End(xlUp).Row + 1
Sheets("Complete").Rows(l2).Value = Sheets("Planning_2016").Rows(k).Value
Sheets("Planning_2016").Rows(k).Delete
Else
End If
Next n
End Sub
Mod Edit: Code tags added
Last edited by a moderator: