Compares the current DateTimeOffset object to a specified DateTimeOffset object and indicates whether the current object is earlier than, the same as, or later than the second DateTimeOffset object.
- other
- An object to compare with the current DateTimeOffset object.
A signed integer that indicates the relationship between the current DateTimeOffset object and other, as the following table shows.
Less than zero The current DateTimeOffset object is earlier than other.
Zero The current DateTimeOffset object is the same as other.
Greater than zero. The current DateTimeOffset object is later than other.
This method compares DateTimeOffset objects by comparing their DateTimeOffset.UtcDateTime values; that is, it determines whether the two objects represent a single point in time, and indicates whether the current object is earlier than, later than, or the same as the other parameter.