Hi all,
this should be an easy question but somehow I fail.
column A Column B
DATE1 DATE2
15-1-1999 15-1-1999
15-1-1999 1-2-1999
15-1-1999 1-3-1999
15-1-1999 1-4-1999
15-1-1999 1-5-1999
15-1-1999 1-6-1999
In column C I want for example a value 3 when date2 is larger than date1 and if not then a value 1
I have:
FinalRow = Cells(Rows.Count, 1).End(xlUp).Row
For i = 2 To FinalRow
Select Case Cells(i, 2).Value >= Cells(i, 1).Value
Case True
Cells(i, 3).Value = 3
Select Case Cells(i, 2).Value >= Cells(i, 1).Value
Case False
Cells(i, 3).Value = 1
Next i
End Sub
but that doesnt work
So how do I compare with using a loop method!
Tnx all
Goofer-
Bookmarks