+ Reply to Thread
Results 1 to 3 of 3

Decimal to Hours

  1. #1
    Registered User
    Join Date
    04-13-2015
    Location
    Luanda
    MS-Off Ver
    Vista
    Posts
    43

    Decimal to Hours

    Hi
    I have developed this VBA formula to retrieves any decimal I input in a range into hour (Please check the attachment)
    But the problem is it only gives me up to 23 hours, when it gets to 24 it gives me zeros all because I have had formatted the cells as time.
    Its working very nice if I input 0.23 or any decimal up to 23 hours but I want to be able to input up to 100 hours or more.

    This is my formula:
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by Isaacadete; 05-05-2015 at 03:22 AM.

  2. #2
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: Decimal to Hours

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here



    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  3. #3
    Registered User
    Join Date
    04-13-2015
    Location
    Luanda
    MS-Off Ver
    Vista
    Posts
    43

    Re: Decimal to Hours

    Thanks... Done

+ 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 Decimal Hours into Hours and Minutes in HH.mn format
    By Cortlyn in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-04-2013, 03:48 PM
  2. [SOLVED] converting decimal hours to regular time but longer than 24 hours
    By rkruse in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-21-2013, 07:45 PM
  3. [SOLVED] Decimal Time to Hours and Minutes over 24 hours in total
    By FlyingTiger in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-17-2012, 06:18 AM
  4. subtract decimal hours from formatted hours
    By each in forum Excel General
    Replies: 2
    Last Post: 10-28-2008, 05:16 PM
  5. how to add hours and show actual hours not decimal numbers
    By TWERNER in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 08-21-2006, 03:40 AM

Tags for this Thread

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