Is there a command to display number of seconds as hrs:min:seconds?

Klaus major-k klaus at major-k.de
Thu Oct 17 06:23:07 EDT 2019


Hi Mark,

> Am 17.10.2019 um 12:21 schrieb Mark Waddingham via use-livecode <use-livecode at lists.runrev.com>:
> 
> On 2019-10-17 10:50, Klaus major-k via use-livecode wrote:
>> save some lines by setting the numberformat first (lazy moi :-)
>> ...
> Save even more lines by using format, div and mod...
> 
> function formatRemainingTime pSeconds
>  return format("%02d:%02d:%02d", pSeconds div 3600, (pSeconds mod 3600) div 60, pSeconds mod 60)
> end formatRemainingTime

Sheeeeeesh... :-D

> Warmest Regards,
> 
> Mark.

Best

Klaus

--
Klaus Major
https://www.major-k.de
klaus at major-k.de





More information about the use-livecode mailing list