I'm working with some time increments that were entered
into the database
in decimal format. 1.5 is 1 hour 30 minutes...
Can anyone think of a way to format 1.5 as 1:30, or .75 as :45, etc?
Take off the integer, then multiply the remaining decimal value by 60 -
it should give you the
jon hall wrote:
I'm working with some time increments that were entered into the database
in decimal format. 1.5 is 1 hour 30 minutes...
Can anyone think of a way to format 1.5 as 1:30, or .75 as :45, etc?
Get the number after the decimal point, keep it as a fraction and
multiply by
#TimeFormat(the_time_in_hours/24, HH:mm)#
I use this all the time to format things like elapsed time in HH:mm:ss. You
might want to be careful if the value goes over 24 hours, howerver. If you
have a value of 36.5, for example, I believe CF would then format it to 12:30.
- Original
3 matches
Mail list logo