c# datetime get difference in days code example
Example: c# calculate difference between two dates in days
(EndDate - StartDate).TotalDays //double
(EndDate.Date - StartDate.Date).Days //int
(EndDate - StartDate).TotalDays //double
(EndDate.Date - StartDate.Date).Days //int