+ Reply to Thread
Results 1 to 6 of 6

Custom format cell

  1. #1
    Forum Contributor
    Join Date
    11-28-2008
    Location
    Reykjavík, Iceland
    MS-Off Ver
    Any of: 2003 & 2007
    Posts
    412

    Custom format cell

    Hi,

    I like to subtract one date from another.
    The two dates look as: dd/mm/yyyy hh:mm
    I know how to achieve that with a little more sophisticated formula than a simple subtraction like in column C.
    However I'm curious about achieving that by only custom formatting leaving the formula Intact.
    I am familiar with the [h]:mm format but could not make [d] [h]h:mm work.
    Thanks, Elm
    Attached Files Attached Files
    Last edited by DonkeyOte; 11-24-2009 at 02:22 PM. Reason: corrected typo in Title

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Cusrtom format cell

    I knew I said I wouldn't but...

    You can't show cumulative days (above 31) in XL like you can minutes, seconds.

    If you want in one cell then you have (as you infer) no option but to return as a text string, ie:

    =INT(B3-A3)&" "&TEXT(MOD(B3-A3;1);"hh:mm")
    Last edited by DonkeyOte; 11-24-2009 at 02:07 PM. Reason: changed delimiter

  3. #3
    Forum Contributor
    Join Date
    11-28-2008
    Location
    Reykjavík, Iceland
    MS-Off Ver
    Any of: 2003 & 2007
    Posts
    412

    Re: Cusrtom format cell

    Thanks, but as I have stated - I am familiar with more than one possible formula to achieve that.
    I will wait for more replies regarding custom formatting only.
    Elm

  4. #4
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Cusrtom format cell

    No problem - good luck with that ... but as stated, you can't show cumulative days via Custom Formatting - the option simply does not exist - however I accept there is no need to take my word for it.

    (and I did state: "as you infer", )
    Last edited by DonkeyOte; 11-24-2009 at 02:22 PM.

  5. #5
    Forum Contributor
    Join Date
    11-28-2008
    Location
    Reykjavík, Iceland
    MS-Off Ver
    Any of: 2003 & 2007
    Posts
    412

    Re: Custom format cell

    Not fair,

    You edited your first post and added the statement.
    It wasn't there when I first read and replied.

    I will take your word for it...
    Thanks.

  6. #6
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Custom format cell

    In fairness I edited my post before your reply - you can see the time in the Edit box (Edit completed a full 8 minutes before your reply)

    I'm not one for editing my posts if it throws the continuity of the thread later on... the edit in question was merely so that the formula reflected your locale (ie comma to semi colon)

    I would be the first to admit that I did edit the narrative after I initially posted it but that was pre 18:07 UK time - ie almost immediately (and I do this a lot because my spelling alone is woeful!)

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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