set wakeTime to "21:01"
set oldDelims to AppleScript's text item delimiters
set AppleScript's text item delimiters to {":", " "}
set {wakeHour, wakeMin} to text items of wakeTime
set AppleScript's text item delimiters to oldDelims
set h to wakeHour as integer
display dialog h
-->21
if h < 13 then
set amOrPm to " am"
else
set amOrPm to " pm"
end if
set m to wakeMin as integer
if m < 10 then set m to "0" & m
set wakeTime to (h & ":" & m & amOrPm)
display dialog wakeTime as string
-->21:01 pm
set WakeUpTime to short date string of (current date)
set WakeUpTime to date (WakeUpTime & space & wakeTime)
(time string of WakeUpTime)
display dialog WakeUpTime as string
--> Monday, September 7, 2009 9,01:00 AM
NOTE this last is tomorrow.
I just tried it with time set to 24 hours, same thing.
What Time Zone /locale are you? I'm MST Zone, USA.