Have you even looked at the DateTime class in C#?
One of the constructors is:
public DateTime(
int year,
int month,
int day
)
So, create two
DateTime
s and compare them however you're going to compare them. You can use
DateTime.CompareTo(DateTime)
.
This is pretty simple stuff and next time I would suggest starting by googling "compare to Dates in C#".