+ Reply to Thread
Results 1 to 9 of 9

VLOOKUP to reference allowed break times

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

    VLOOKUP to reference allowed break times

    I need some formula for columns M &N rows 83 - 119 to calculate the appropriate off or break time of employees. this formula needs to go into E103:E109 & K103:K109.


    i tried using

    =VLOOKUP(MINUTE($J$48)+HOUR($e103)*60,$M$84:$N$119,2,1)

    but it didnt work


    I need all kinds of help all around, anything you have will be appreciated.
    Attached Files Attached Files
    Last edited by Kmac; 04-02-2010 at 02:45 AM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: VLOOKUP to reference allowed break times

    What should the result in those E103:E109 and K103:K109 be? and based exactly on what?

    You have the same times listed in column M several times over with differing column N values... how do you know which to choose?
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

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

    Re: VLOOKUP to reference allowed break times

    column M was formatted wrong it has been corrected.

    column m is the total time of any given shift. column in is the amount of time they are allowed to take breaks.

    the total amount of time of their shifts are in e69:82 & k69:82

    in e102:109 i need the total amount of excess break time.

    in d102:109 it has the total amount of break time they had.

    so basically in e102:109 i need to reference and also the m and n columns. and give the the total amount of time they are allowed based on the duration of their shift, and then subtract that from the number in d102:109.
    Attached Files Attached Files

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: VLOOKUP to reference allowed break times

    This is a guess...as I am not quite sure I understood.

    In E103:

    Please Login or Register  to view this content.
    copied down.

    If not right... tell me what the answers should be and how they are derived at.

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

    Re: VLOOKUP to reference allowed break times

    no that did not work it is giving me a #n/a error. here i made a simpler version, kind of.

    E2:16 shows the duration of the shift they worked for every day of the week.

    We allow employees "off time" or break time that our system tracks automatically, based on the duration of their shift. ie if they work 8 hours, they get 30 min of break time.

    the break time chart is in column's G & H. G shows the the length they work and H shows how much break time they get for working that length.

    so in E:20 i need it to show how i have it in the example there. it need to look at E3 to see how long the shift was, 7 hours. and then look at the break time chart and see that a 7 hour shift allows employees 26 minutes of break time. then it needs to subtract the allowed amount of break time from their total "off" or break time in D:20 giving me the total excess break time they took in E:20
    Attached Files Attached Files

  6. #6
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: VLOOKUP to reference allowed break times

    It would help if you first adjusted your ranges to suit your new data locations....

    And second that you don't type extra spaces after Mon, Tues, etc... in your lookup table...

    Also I added a row in the G:H data to account for when value in your top table are less than 4...
    Attached Files Attached Files

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

    Re: VLOOKUP to reference allowed break times

    no it is not working correctly. i changed D20 to 45 minutes and it showing 10 excess and that is wrong. it should show 11 and it is showing 10.

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

    Re: VLOOKUP to reference allowed break times

    bumpity bump bump

  9. #9
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: VLOOKUP to reference allowed break times

    I had kept your -"00:30" in the formula and not sure what purpose that had..

    Maybe?

    Please Login or Register  to view this content.

+ 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