+ Reply to Thread
Results 1 to 7 of 7

Convert General Number To Hours?

  1. #1
    Forum Contributor
    Join Date
    01-29-2015
    Location
    .
    MS-Off Ver
    2010
    Posts
    313

    Convert General Number To Hours?

    I have been trying to come up with a resolution for this all day. I have the number 30.00 in let's say A2 that represents number of hours. I want it to be formatted in a way that shows 30:00:00(30 hours) so that I can add it to the current date and time. Is this possible?

  2. #2
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Convert General Number To Hours?

    You could do

    =NOW()+TIME(A2,0,0)

  3. #3
    Forum Contributor
    Join Date
    06-18-2014
    Location
    USA
    MS-Off Ver
    2013
    Posts
    142

    Re: Convert General Number To Hours?

    Excel treats dates as numbers, so you dont have to format your hours input differently. If in A2 you have hours (in your example, 30 hours), then if you had current date and time in B2, using the formula
    Please Login or Register  to view this content.
    formula, then in column C2 you could use this formula
    Please Login or Register  to view this content.
    to get the date and time when the hours in A2 are added to B2 (current date and time).

  4. #4
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: Convert General Number To Hours?

    That's wrong....ignore that

    Try
    =NOW()+A2/24

  5. #5
    Forum Contributor
    Join Date
    01-29-2015
    Location
    .
    MS-Off Ver
    2010
    Posts
    313

    Re: Convert General Number To Hours?

    I apologize in advance for not attaching an excel sheet but this is what I am looking for. My current settings are general except the date and time at the top (05/06/2015 17:00) I want to add 30 hours to this time but I cant seem to get it to work correctly.
    234.PNG

  6. #6
    Forum Contributor
    Join Date
    01-29-2015
    Location
    .
    MS-Off Ver
    2010
    Posts
    313

    Re: Convert General Number To Hours?

    I figured it out . Lets say my current date and time was in cell B1 and the total hours in cell A2(General number format). You would then need to take B1+A2/24, change your format settings in the custom options to under time( [hh]:mm) and you're done. Thank you!

    PS: I was off by an hour in my example

  7. #7
    Forum Contributor
    Join Date
    06-18-2014
    Location
    USA
    MS-Off Ver
    2013
    Posts
    142

    Re: Convert General Number To Hours?

    I believe in your example the input would be 31 hours, not 30, but, the formula in the yellow box would be
    Please Login or Register  to view this content.
    assuming that a2 is where the hours are being input. Also, make sure that you format the cell highlighted in yellow the same format as your current time cell.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] convert general number to date format
    By Jhon Mustofa in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 03-08-2014, 09:12 AM
  2. [SOLVED] Convert General Number (##:##) to time format (mm:ss)
    By vamosj in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 07-02-2013, 01:06 PM
  3. Convert time to general number
    By Rmnticjas in forum Excel - New Users/Basics
    Replies: 5
    Last Post: 04-23-2012, 01:28 PM
  4. how do I convert a general number to a time format?
    By doveness in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 05-25-2006, 07:45 PM
  5. [SOLVED] General Number field has 19820431. How to convert to 04/31/1982?
    By Leigh in forum Excel General
    Replies: 6
    Last Post: 03-23-2006, 02:45 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1