I need to compare two DateTime variables named as t1 and t2 using VB.NET
2003. If t1 is any earlier time as t2, only then program should do
something like...
If (t1 < t2) Then
'DoSomethingHere...
End If
But I don't figue out how comparing DateTimes is working.
I tried to compare these variables with same time in Immediate-window...
?t1
#3/30/2005 10:18:14 AM#
?t2
#3/30/2005 10:18:14 AM#
?DateTime.Compare(t1, t2)
1
?DateTime.Compare(t2, t1)
-1
?t1.CompareTo(t2)
1
?t1 = t2
False
?t1.Equals(t2)
False
....so why these t1 ja t2 variables content is not same in this case
according comparing results !?!
--
Thanks in advance!
Mika