A time's hour.

Hour = SRP_Time("Hour", Time)

Returns

The hour component of an OI time.

Parameters

ParameterDescription
TimeA time in OI internal format. (REQUIRED)

Remarks

The "Hour" service returns the hour component of an OI time. The result is an integer between 0 and 23 with 0 being the midnight hour and 23 being the 11pm hour. If an OI time represents 12:41:08pm, this service would return 12. If the time is 4:23:32pm, this service would return 16. If the given time not valid, "" is returned.

Examples

// Get the current hour
Hour = SRP_Time("Hour", Time())

// Get the current hour in UTC
Hour = SRP_Time("Hour", SRP_Time("Now", 1))

// Get a hard coded time's hour
Hour = SRP_Time("Hour", 56013)

// Parse a time's hour
Time = SRP_Time("Parse", "12:41:08pm", "h:mm:sstt")
Hour = SRP_Time("Hour", Time)
  • No labels