![]() |
Convert a number to a time
I have the following number 232.5 which is 232 hours and 0.5 of an hour. I
want to convert this to 232 hours and 30 minutes or 232:30. How can i do this? I know i need to multiply the decimal by 60, but how can i perform a calculation on just the decimal part of a number and not the whole number? |
Convert a number to a time
Depending what you wish to do excel stores times as well as dates as numbers, with 1 being a full day. An option is to divide everything by 24 and use a custom format of dd hh:mm although this will express the hours as days and hours It depends what you want to do really -- Dav ------------------------------------------------------------------------ Dav's Profile: http://www.excelforum.com/member.php...o&userid=27107 View this thread: http://www.excelforum.com/showthread...hreadid=502807 |
Convert a number to a time
suppose you have 232.5 in cell A1. in cell B1 type
=((A1-ROUNDDOWN(A1,0))*60/100)+ROUNDDOWN(A1,0) That should do the trick. Steven. "Jack" wrote: I have the following number 232.5 which is 232 hours and 0.5 of an hour. I want to convert this to 232 hours and 30 minutes or 232:30. How can i do this? I know i need to multiply the decimal by 60, but how can i perform a calculation on just the decimal part of a number and not the whole number? |
Convert a number to a time
Divide by 24 and format the resultant cell as [h]:mm
-- HTH Bob Phillips (remove nothere from email address if mailing direct) "Jack" wrote in message ... I have the following number 232.5 which is 232 hours and 0.5 of an hour. I want to convert this to 232 hours and 30 minutes or 232:30. How can i do this? I know i need to multiply the decimal by 60, but how can i perform a calculation on just the decimal part of a number and not the whole number? |
Convert a number to a time
Thanks Bob. I played around with custom formats, but could not get it right.
This works perfectly. "Bob Phillips" wrote: Divide by 24 and format the resultant cell as [h]:mm -- HTH Bob Phillips (remove nothere from email address if mailing direct) "Jack" wrote in message ... I have the following number 232.5 which is 232 hours and 0.5 of an hour. I want to convert this to 232 hours and 30 minutes or 232:30. How can i do this? I know i need to multiply the decimal by 60, but how can i perform a calculation on just the decimal part of a number and not the whole number? |
All times are GMT +1. The time now is 05:56 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com