errgghhh.... that's not good.... okie, something that will work.... (although there may be better ways, I haven't played much with time values)
reformat your time to 24 hour using something like...
Code:
24Hour(ti) > 24Hour(tiorder2(t2))
Function 24Hour (myTime)
arrTime = split("9:00:01AM",":")
AMPM = mid(arrTime(2),3)
myHour = arrTime(0)
myMinute = arrTime(1)
mySecond = left(arrTime(2))
if AMPM="PM then myHour = myHour +12
24hour = myHour & myMinute & mySecond
end function