+ Reply to Thread
Results 1 to 17 of 17

Time formula going back to zero?

  1. #1
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Time formula going back to zero?

    So i am basically making a way to track payroll. Here is the formula i have in my E column

    =IF(D2<C2,D2+1,D2)-C2

    and so forth with the times entered into the c and d columns.

    In the last e column where i want the total for the week i have:

    =SUM(E2:E15)

    problem is that when i enter more than 3 or more start and stop times the sum cell reverts back to zero, when all the other e still have the number of hours.

    what is going on?
    Last edited by Kmac; 03-31-2010 at 03:39 AM.

  2. #2
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    Try formatting your sum as [h]:mm:ss ( see format cells - custom)
    That should help

  3. #3
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    no. it still shows up as 0 if more than 3 times are entered. if i only enter 1 time or times then it will add it. but for some reason 3 or more is still 0

  4. #4
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    When you add more tha three, is the total more than 24 hrs?
    Also if you attach a sample file we can see what is going wrong

  5. #5
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    Yes three 8 hours shifts makes it 24 hours. If i use smaller shifts, i can include more than 3. so i guess its a 24 hour thing?


    I thought about attaching the file, but i am unsure of where i would upload it to link to it.

  6. #6
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    Under the reply box click "go advanced"
    Click on the attachments link and upload your sheet

  7. #7
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    of course its that easy. well i already uploaded it here

    http://www.filefactory.com/file/b0eg...yrollcalc.xlsx

    but here is the xls too
    Attached Files Attached Files

  8. #8
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    I added some intervals to your sheet and formatted as I suggested and it works OK.
    Is that what you need ? ( see total in red)
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    Yes you are my hero! I did change it like you said but it did not work for me =/

    what do you mean by you changed intervals?

  10. #10
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    Just added some hours to go over the 24

  11. #11
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    Well i don't know why it worked for you, and not me. But thanks!!

  12. #12
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    If you are satisfied with the solution(s) provided, please mark your thread as Solved.

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save

  13. #13
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    ok, now its not working again.

    i changed the shifts, making them longer one week 64 hours. to try and see if overtime formula worked. number are not adding right again!!!
    Attached Files Attached Files

  14. #14
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    Everything looks right. Where do you get an error?

    BTW avoid AT ALL COSTS using merged cells, they will cause trouble if you need them to analyze data

  15. #15
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    At the top where it has the summary. week 1 regular hours should be 40 not 16.

  16. #16
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time formula going back to zero?

    Same thing, wrong format ! you should use [h]:mm:ss the h has to be between "brackets"

  17. #17
    Registered User
    Join Date
    03-29-2010
    Location
    Houston
    MS-Off Ver
    Excel 2007
    Posts
    57

    Re: Time formula going back to zero?

    oh, thanks!

+ 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