DateTimeOffset Greater Than Or Equal Operator
using System;
using System.Globalization;
public class Test
{
public static void Main()
{
DateTimeOffset date1 = new DateTimeOffset(2007, 6, 3, 14, 45, 0, new TimeSpan(-7, 0, 0));
DateTimeOffset date2 = new DateTimeOffset(2007, 6, 3, 15, 45, 0,new TimeSpan(-7, 0, 0));
DateTimeOffset date3 = new DateTimeOffset(date1.DateTime, new TimeSpan(-6, 0, 0));
DateTimeOffset date4 = date1;
Console.WriteLine(date1 >= date2);
Console.WriteLine(date1 >= date3);
Console.WriteLine(date1 >= date4);
}
}
Related examples in the same category