G
Guest
Hello
I need to step through each cell of a particular column, check the contents to the previous cell, and then preform an action based on the outcome. Below is my code. Please help if you can
Thanks, Jo
With Worksheets("Source Data"
For i = 2 To .Range("e").Rows.Coun
If .Range("E" + i) <> .Range("E" + (i - 1)) The
Range("e" + i).Selec
Selection.Cop
Worksheets("Gap").Range("b11").End(xlDown).Offset(1, 0).Selec
Selection.PasteSpecial Paste:=xlPasteValue
.....etc
End I
Next i
I need to step through each cell of a particular column, check the contents to the previous cell, and then preform an action based on the outcome. Below is my code. Please help if you can
Thanks, Jo
With Worksheets("Source Data"
For i = 2 To .Range("e").Rows.Coun
If .Range("E" + i) <> .Range("E" + (i - 1)) The
Range("e" + i).Selec
Selection.Cop
Worksheets("Gap").Range("b11").End(xlDown).Offset(1, 0).Selec
Selection.PasteSpecial Paste:=xlPasteValue
.....etc
End I
Next i