What is the syntax to return an hour for a given time?

Hour(time)
‘yields a range from 0-23
‘example
MsgBox (Hour("2:12:42 PM")) 'returns 14
MsgBox (Hour("22:32:57")) 'returns 22
MsgBox (Hour("12:32AM")) 'returns 0
Advertisements