+ Reply to Thread
Results 1 to 7 of 7

Help with time formula please

  1. #1
    Registered User
    Join Date
    03-15-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    3

    Help with time formula please

    I am trying to find a formula to keep track of how late my employees are to work. I am not super computer literate so I have tried what I know but nothing works. I would like it to calculate off of the set time they are supposed to clock in. For example, in A1 I have employee name (Michelle), B1 the time she clocked in (7:01), in C1 I would like a formula to show the time difference between 7:01 and 6:45 (the time she should have clocked in). I have four employees I would like to do this for, all have the set clock in time of 6:45. Everything I have tried gives me weird answers instead of displaying 0:16. Is this even possible?

    Thanks in advance for your help.

  2. #2
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: Help with time formula please

    Hi jenn,

    welcome to the forum.
    Can you share a sample workbook along with your expected results.. thx


    Regards,
    DILIPandey
    <click on below * if this helps>
    DILIPandey, Excel rMVP
    +919810929744 (India), +971528225509 (Dubai), [email protected]

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Help with time formula please

    Hi,

    What formula are you using?
    With a time of 6:45 in A1, and 7:01 in B1, then in C1, =B1-A1 will result in 0:16 assuming the formatting of C1 is a time format. What 'weird' numbers are you getting?
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    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
    52,938

    Re: Help with time formula please

    Hi and welcome to the forum

    Try this, copied down...
    =B1-TIME(6,45,0)
    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

  5. #5
    Registered User
    Join Date
    03-15-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Help with time formula please

    This is an example of the data I am entering. It is the "min past 6:45" column I want to see if there is a formula for.

    6:45 MICHELLE MIN PAST 6:45
    2/12/2017 6:58 0:13
    2/13/2017 6:55 0:10
    2/14/2017 9:00 0:15
    2/15/2017 6:45 0:00
    2/16/2017 6:54 0:09
    WKLY TOTAL 0:47

    I changed the format of the cells and the answer now looks right, thanks Richard!

    Is there way to always have the one cell locked in a formula? For example, I put 6:45 in A1 and the formula of =B2-A1 in C2 to get the answer of 0:13 but when I tried to copy the formula to C3, it changed the formula to =B3-A2 when I need it to say =B3-A1. How do I lock the A1 in place?

  6. #6
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Help with time formula please

    Hi,

    Making cells absolute vs relative is basic to Excel.
    To 'lock' a reference preface the row number or column letter or both with a $ sign.
    i.e.
    =$A$1

  7. #7
    Registered User
    Join Date
    03-15-2013
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Help with time formula please

    Perfect! Thank you so much for your help!!!

+ 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