In C#, how do you compare 2 dates? I am not interested in the time, just the Dates.
This example says that t3 is less than t4. How do I compare only the Date portion of t3 and t4? In this case, I want the Compare to say the two values are equal.
DateTime t3 = DateTime.Today;
DateTime t4 = DateTime.Now;
int myint = DateTime.Compare(t3, t4);
MessageBox.Show(myint.ToString());
Thanks,
Jerry
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only