Whole numbers set in seconds to Hour Format "00:00:00"

Newbie987654321

New Member
Joined
Mar 13, 2018
Messages
9
Hi. I need your to convert whole numbers in seconds in a time format. May I know an easier way to do this with this format "hh:mm:ss"? I tried to manually calculate. 3600 (secs) is already equivalent to 1 (hr), but if I format it to time, I can't seem to find "1:00:00" there. It appears as 24:00:00. Please help.
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Hi

I found when coverting whole numbers to time format simply create another column (Column B) and use this formula in the new column =(A1/24), this should then give you the desired time format you're looking for, let me know if this works?
 
Upvote 0
Hi,

If you're trying to convert Seconds to Hours, you can do this, Column B Cells formatted as Time (either 12 or 24 Hour format), if you may have More than 24 hours, than Custom Format as [h]:mm:ss


Book1
ABC
136001:001:00:00
298762:442:44:36
3864000:0024:00:00
490000210:00250:00:02
5
6Formatted as 24 hourCustom formatted [h]:mm:ss
Sheet28
Cell Formulas
RangeFormula
B1=A1/3600/24
C1=A1/3600/24
 
Upvote 0
@Newbie.... If time in decimal seconds is in A1 (e.g. 1234 for 1234 seconds), ostensibly use A1/86400 formatted as [h]:mm:ss .

However, it would be prudent to use =--TEXT(A1/86400,"[h]:m:s") formatted as [h]:mm:ss , especially if you might compare the result with time that you enter manually.

The use of TEXT should avoid anomalies due to binary floating-point arithmetic. The double negate ("--") returns numeric Excel time.

The use of [h] instead of h is a "good programming practice" when formatting calculated time. It allows for the possibility, no matter how unlikely, that the result is 24 or more hours.

If the original decimal seconds are accurate to milliseconds, use --TEXT(A1/86000,"[h]:m:s.000").

And do not use TEXT at all if the original decimal seconds are accurate to greater precision (e.g. microseconds).
 
Last edited:
Upvote 0
Hi,

If you're trying to convert Seconds to Hours, you can do this, Column B Cells formatted as Time (either 12 or 24 Hour format), if you may have More than 24 hours, than Custom Format as [h]:mm:ss


Book1
ABC
136001:001:00:00
298762:442:44:36
3864000:0024:00:00
490000210:00250:00:02
5
6Formatted as 24 hourCustom formatted [h]:mm:ss
Sheet28
Cell Formulas
RangeFormula
B1=A1/3600/24
C1=A1/3600/24

Hi Guys. Im good with this. I guess i was looking for the formula 3600/24. Thank you for all of your help guys! :)
 
Upvote 0

Forum statistics

Threads
1,214,914
Messages
6,122,211
Members
449,074
Latest member
cancansova

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top