+ Reply to Thread
Results 1 to 14 of 14

Making a format as a genuine value

  1. #1
    Registered User
    Join Date
    08-13-2012
    Location
    Oman
    MS-Off Ver
    365
    Posts
    23

    Making a format as a genuine value

    I am working with hours difference split between two days. i.e start work at 23:00 on 1st and finish at 07:00 on the second.

    Now when it comes for easier typing of the hours I format the cell for CUSTOM 00\:00 so I can type the hours and minutes continuously and the format takes care of placing the colon , that works fine as a format but doesn't return the same result compared to typing the hours the traditional way with the colon inserted manually.

    I am after using the format for easier typing and getting the correct result.

    Thanks in advance


    Image 1.png
    Last edited by kmsalehi; 06-27-2016 at 09:33 PM. Reason: typing mistake

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Making a format as a genuine value

    that works fine as a format but doesn't return the same result compared to typing the hours the traditional way with the colon inserted manually.
    Formatting is only a cosmetic change to the appearance of the data in a cell, it does not change the underlying value/contents of the cell. If you want the cell to contain time, then you need to enter it that way.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,936

    Re: Making a format as a genuine value

    Total time:

    Please Login or Register  to view this content.
    You can also use hidden helper columns for the in and out times
    Last edited by protonLeah; 06-28-2016 at 01:36 AM.
    Ben Van Johnson

  4. #4
    Registered User
    Join Date
    08-13-2012
    Location
    Oman
    MS-Off Ver
    365
    Posts
    23

    Re: Making a format as a genuine value

    Quote Originally Posted by protonLeah View Post
    Total time:

    Please Login or Register  to view this content.
    You can also use hidden helper columns for the in and out times
    didnt work it always comes up with a result of ############

  5. #5
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,936

    Re: Making a format as a genuine value

    You did not post a workbook, nor indicate which cells were holding which values, so the formula was just a generic. Did you replace: "time out cell" with the actual cell address for time in, etc?
    The formula would then look like:
    Please Login or Register  to view this content.
    Or what ever your actual cell addresses are.
    Last edited by protonLeah; 06-30-2016 at 07:02 PM.

  6. #6
    Registered User
    Join Date
    08-13-2012
    Location
    Oman
    MS-Off Ver
    365
    Posts
    23

    Re: Making a format as a genuine value

    Attached is the sample file.
    Attached Files Attached Files

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Making a format as a genuine value

    wow thats quite some delayed reply...almost 4 years?

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,471

    Re: Making a format as a genuine value

    Why did you post in the Outlook section?
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

  9. #9
    Registered User
    Join Date
    08-13-2012
    Location
    Oman
    MS-Off Ver
    365
    Posts
    23

    Re: Making a format as a genuine value

    I know. My bad. Still navigating myself through the replies. Figured how to add (solved) and saw this was hanging.

  10. #10
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Making a format as a genuine value

    Quote Originally Posted by AliGW View Post
    Why did you post in the Outlook section?
    I noticed that too, but was more intrigued by the delay in replying

  11. #11
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,471

    Re: Making a format as a genuine value

    So is it solved or not?

  12. #12
    Registered User
    Join Date
    08-13-2012
    Location
    Oman
    MS-Off Ver
    365
    Posts
    23

    Re: Making a format as a genuine value

    Not yet

  13. #13
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,936

    Re: Making a format as a genuine value

    You subtracted the start time from the end time in row 10 and you left out the outer MOD() function as used in G9:
    Please Login or Register  to view this content.

  14. #14
    Registered User
    Join Date
    08-13-2012
    Location
    Oman
    MS-Off Ver
    365
    Posts
    23

    Re: Making a format as a genuine value

    That worked now. Thanks

+ 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] Genuine Paid Job (£100 / $169): Tidy up code - prevent crashes - Please contact ASAP
    By r2fro in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-01-2014, 12:22 AM
  2. [SOLVED] Preserving a cell format while making One Column
    By radionut in forum Excel Programming / VBA / Macros
    Replies: 18
    Last Post: 08-20-2013, 06:14 AM
  3. was i born yesterday or is this a genuine problem
    By martindwilson in forum The Water Cooler
    Replies: 2
    Last Post: 08-06-2011, 02:48 AM
  4. Making my own Category under Format Cells...
    By tenswmmsc in forum Excel General
    Replies: 3
    Last Post: 07-16-2010, 12:46 PM
  5. Trouble with date format when making one range equal to another
    By lightsandsirens in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-18-2009, 11:57 PM
  6. Making the user be able to format a text box
    By gruebz in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-08-2007, 04:52 AM
  7. Making a number have Text format
    By Howard Kaikow in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 01-06-2006, 11:30 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