Hello guys!

I have been writing a vba code for a while and I cant find the mistake that I am making... I have a big table and I am comparing the values between column U and V column U and W column AB with AC and finally AB with AD. So I am making 4 comparisons for each row. If the difference between any of these comparisons is bigger than a specific value I want to copy and paste the entire row to another sheet.. So, even if one comparison out of the 4 that exist in a row is not good (the difference is bigger), I want the whole row to pasted to the other sheet. .. can you please help??

Sub macro()

Dim mDiff1 As Double

mDiff1 = 0.01

Dim mDiff2 As Double

mDiff2 = 0.03

Dim mDiff3 As Double

mDiff3 = 0.01

Dim mDiff4 As Double

mDiff4 = 0.03

Sheets("TRACKER").Select

For Each cell1 In Range("U2:U" & Range("U" & Rows.Count).End(xlUp).Row)

If cell1.Value - cell1.Offset(0, 1).Value > mDiff1 Then

cell1.Offset(0, 1).Interior.ColorIndex = 3

End If

If cell1.Value - cell1.Offset(0, 2).Value > mDiff2 Then

cell1.Offset(0, 2).Interior.ColorIndex = 5

End If

If cell1.Value - cell1.Offset(0, 1).Value > mDiff1 Or cell1.Value - cell1.Offset(0, 2).Value > mDiff2 Then

**cell1.EntireRow.Copy
**

Sheets("WFR+VFR report").Range("A" & Rows.Count).End(xlUp).Offset(1, 0).PasteSpecial xlPasteValues
End If

Next cell1

For Each cell2 In Range("AB2:AB" & Range("AB" & Rows.Count).End(xlUp).Row)

If cell2.Value - cell2.Offset(0, 1).Value > mDiff3 Then

cell2.Offset(0, 1).Interior.ColorIndex = 3

End If

If cell2.Value - cell2.Offset(0, 2).Value > mDiff4 Then

cell2.Offset(0, 2).Interior.ColorIndex = 5

End If

If cell2.Value - cell2.Offset(0, 1).Value > mDiff3 Or cell2.Value - cell2.Offset(0, 2).Value > mDiff4 Then

**cell2.EntireRow.Copy
**

Sheets("WFR+VFR report").Range("A" & Rows.Count).End(xlUp).Offset(1, 0).PasteSpecial xlPasteValues
End If

Next cell2

End Sub