Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!
on mouseUp
set the twelvehourTime to false
put the long time
put the system time into field "SThhmmss"
end mouseUp
Whilst my field does now show the hh:mm:ss as I wanted, I now have a message box appear which I don't want. What do I add or change for no message box to appear?
When I said it was corrected in my previous answer we were on PM time and unfortunately when midnight passed it then displayed as h:mm:ss and not hh:mm:ss
Can you write the couple of lines of code that pad the hours portion of the time with a "0" if it needs one? In other words, can you make "1" into "01"? Do you know about the itemDelimiter, and how it might be used for this?
on mouseUp
set the twelvehourTime to false
put the long time into tempTime
if the number of chars of tempTime = 7 then
put 0 & tempTime into tempTime
end if
put tempTime into fld "SThhmmss"
end mouseUp