+ Reply to Thread
Results 1 to 8 of 8

date calculations

  1. #1
    Registered User
    Join Date
    11-10-2008
    Location
    Stafford
    Posts
    3

    date calculations

    can anyone tell me how to get excel to calculate the differnece between two dates.


  2. #2
    Valued Forum Contributor mdbct's Avatar
    Join Date
    11-11-2005
    Location
    CT
    MS-Off Ver
    2003 & 2007
    Posts
    848
    It's as simple as subtracting the two dates (or cells containing the dates). Assuming the dates are in A1 and B1. Your formula would be =A1-B1 assuming A1 is the later of the two dates.

  3. #3
    Forum Contributor
    Join Date
    06-23-2007
    Posts
    690
    =a3-a2
    that easy

    change cells to whatever the dates ar ein

  4. #4
    Registered User
    Join Date
    11-10-2008
    Location
    Stafford
    Posts
    3
    yes i tried that bit it just puts another date in the answer cell???

  5. #5
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,702
    That's just a formatting issue. Change the format of the result cell to either general or number

  6. #6
    Registered User
    Join Date
    11-10-2008
    Location
    Stafford
    Posts
    3

    date calculations

    Thanks for coming back daddylonglegs,

    I tried that suggestioon as well but with the following dates for instance: 1/2/1950 and 11/11/2008 the answer cell when converted to either number or general reads 21468 which as I understand it is how excel 'sees' a date.

    what I'm trying to do is to determine a formula that will give me the difference in months between two dates. I work for a training organisation and we have learners on programme for varying lengths of time.

    I need to create a spreadsheet formula that will automatically record the number of months a learner will be on prgramme from his start date to his finish date and express the answer in months.

    any further advice would be much appreciated.

  7. #7
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326
    Hi,
    the DATEDIF function will give you the number of months between two dates try =datedif(startdate,enddate,"m") ( not documented by MS anymore)
    Also do some searching on the forum for this function because there seem to be some problems with it.
    Good luck

  8. #8
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,702
    Quote Originally Posted by catwood View Post
    I tried that suggestioon as well but with the following dates for instance: 1/2/1950 and 11/11/2008 the answer cell when converted to either number or general reads 21468 which as I understand it is how excel 'sees' a date.
    21468 doesn't represent a date, it's the number of days between the two dates. As arthurbr says, you can get the difference in months by using DATEDIF. This function does have some problems but it should work fine for what you need, see further information on DATEDIF here

+ 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