+ Reply to Thread
Results 1 to 5 of 5

Difference between dates

  1. #1
    Registered User
    Join Date
    03-11-2009
    Location
    Rio de Janeiro, Brazil
    MS-Off Ver
    Excel 2003
    Posts
    2

    Difference between dates

    Hey everyone!

    I have four columns in a worksheet: Start Date, Start Time, End Date, End Time. All of them are in text format.

    How could I create a column with the difference in minutes between those two dates? The Date and Time portions are separated as mentioned above.

    Thanks in advance.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Difference between dates

    Can we see this text formatted data? It will substantively effect the answers given.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

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

    Re: Difference between dates

    I suspect you "may" be able to coerce the text values by adding them prior to calculating the difference... eg if we assume Start Date & Start Time are in A2:B2 and End Date & End Time in C2:D2 then:

    E2: =(C2+D2)-(A2+B2)
    Format of cell set to [mm]:ss

    If this doesn't work then as JB says we need to see the data, ie post up a sample file.

  4. #4
    Registered User
    Join Date
    03-11-2009
    Location
    Rio de Janeiro, Brazil
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Difference between dates

    Actually it worked the way you told me DonkeyOte. It was as simple as that. Amazing that I didn't realize it before.

    Thanks for your help.

  5. #5
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Difference between dates

    If that takes care of your need, be sure to EDIT your original post (Go Advanced) and mark the PREFIX box [SOLVED]

+ 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