+ Reply to Thread
Results 1 to 3 of 3

Need help with formula involving dates

Hybrid View

  1. #1
    Registered User
    Join Date
    03-16-2010
    Location
    Lexington Kentucky
    MS-Off Ver
    Excel 2003
    Posts
    1

    Need help with formula involving dates

    Hi,
    I'm comparing two dates or ages (in days) based on dates. I want to get the difference in an integer form (number of days). I have tried using both IF and DATEDIF functions.
    Problem is, the value comes out as a date. Sometime back in 1900, usually. Neat trick, that, but totally unhelpful.
    Here's the one formula, which is not performing as advertised:
    =DATEDIF(G4,TODAY(),"d")
    where G4 represents a manually entered date like 4/1/2009.

    Why is this happening? What can I do?

  2. #2
    Forum Expert sweep's Avatar
    Join Date
    04-03-2007
    Location
    Great Sankey, Warrington, UK
    MS-Off Ver
    2003 / 2007 / 2010 / 2016 / 365
    Posts
    3,454

    Re: Need help with formula involving dates

    Hi,

    Format the cell containing the result as "General".
    Rule 1: Never merge cells
    Rule 2: See rule 1

    "Tomorrow I'm going to be famous. All I need is a tennis racket and a hat".

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Need help with formula involving dates

    Welcome to the forum.

    Please take a few minutes to read the forum rules, and then amend your thread title accordingly.

    Thanks.
    Entia non sunt multiplicanda sine necessitate

+ 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