< Day Day Up > |
Hour ()Category: Time Syntax: Hour ( time ) Parameters: time ”any valid time value or expression that returns a valid time value. Description: The Hour() function returns an integer representing the number of hours specified by the time parameter. Examples: Hour ("10:45:20") = 10 Hour ("12:15 am") = 0 Hour ("11:15 pm") = 23 Hour ( Get ( CurrentTime )) will return a value from 0 to 23. Comments: When its parameter represents a specific time of day, the Hour() function returns a value from 0 to 23. To map this into the more familiar 1 to 12 range, you can use the following formula: Mod ( Hour (time) -1 ; 12 ) + 1 The Hour() function can return an integer value outside of the 0 to 23 range when its parameter represents a duration rather than a specific time of day. For instance, Hour ("65:12:53") returns 65 . |
< Day Day Up > |