The number of days between datetimes.
Days = SRP_DateTime("Span", FromDateTime, ToDateTime)
Returns
The number of days between two datetimes
Parameters
Parameter | Description |
---|---|
FromDateTime | A starting datetime in OI internal format. (REQUIRED) |
ToDateTime | An ending datetime in OI internal format. (REQUIRED) |
Remarks
The "Span" service calculates the number of days between two datetimes. The result will be positive if the starting datetime comes before the ending datetime and negative if the ending datetime comes first. This service is the same as the "DaySpan" with the Fractional parameter set to 1.
Examples
// Get the number of days between two datestimes From = SRP_DateTime("Parse", "Monday, December 8, 1941 at 7:51:43am", "DDD, MMMM D, YYYY at h:mm:sstt") To = SRP_DateTime("Parse", "Thursday, March 30, 1978 at 12:41:08pm", "DDD, MMMM D, YYYY at h:mm:sstt") Days = SRP_DateTime("Span", From, To)