d2jsp
Log InRegister
d2jsp Forums > Off-Topic > General Chat > Homework Help > Excel If Statement
Add Reply New Topic New Poll
Member
Posts: 17,661
Joined: Apr 19 2009
Gold: 119.26
Oct 1 2013 02:14pm
Why is this returning false? I need it to be 0:00 or 0



=IF(G7>$C$11,$D$11, IF(G7<$C$9,$D$9, IF(G7>$C$9,$D$10)))

Also how do I get the sum of G? It is supposed to be hours, not time. But it keeps adding up wrong.

If anyone can set it up better and then link me to download link or show the formulas you used I'd pay.

Final heads should be Start (time) Break (length in minutes or hours) End (time) Before Break (Total hours worked before break) After Break (total hours worked minus break)

I then need a total of after break column to let me know how many hours I worked this week.

This post was edited by JukeBOXX on Oct 1 2013 02:32pm
Member
Posts: 17,661
Joined: Apr 19 2009
Gold: 119.26
Oct 1 2013 03:00pm
Okay I got it working without an if statement, by entering break start and end time and using =SUM((C19-C18)*24,(C17-C16)*24) keep in mind cell reference have changed.

I would still like to use an if statement to determine whether I had a break or not so that I not do need to enter times of break, I can just enter the time I started and ended work and it can determine the rest itself.
Member
Posts: 21,893
Joined: Mar 27 2009
Gold: 12,408.00
Oct 1 2013 03:55pm
They really need to teach R1C1 early.
Member
Posts: 9,029
Joined: Jul 5 2008
Gold: 3.75
Oct 1 2013 06:41pm
For the sum function, create a helper column and put in this formula. A1 is hypothetical here ofc.

=HOUR(A1)+MINUTE(A1)/60

Instead of the if function, I believe you can use a index/match. I may have some more time this week to think about it.

*Also if you're doing this consistently, would recommend recording a macro for it. Without VBA knowledge you won't be able to clean up the code but there's not much going on anyways
so there should be no performance issues. Remember to click the "relative references" when recording if applicable.

This post was edited by Legolas_RH on Oct 1 2013 06:43pm
Member
Posts: 17,661
Joined: Apr 19 2009
Gold: 119.26
Oct 2 2013 12:26pm
Quote (Dontrunaway @ Oct 2 2013 05:55am)
They really need to teach R1C1 early.


Why? $ works fine.

Quote (Legolas_RH @ Oct 2 2013 08:41am)
For the sum function, create a helper column and put in this formula. A1 is hypothetical here ofc.

=HOUR(A1)+MINUTE(A1)/60

Instead of the if function, I believe you can use a index/match. I may have some more time this week to think about it.

*Also if you're doing this consistently, would recommend recording a macro for it. Without VBA knowledge you won't be able to clean up the code but there's not much going on anyways
so there should be no performance issues. Remember to click the "relative references" when recording if applicable.


I need to do it every week for every day. The girl in pay office has no clue what she is doing and is paying people wrong on a weekly basis. I only just started checking my pay and noticed it is wrong. So I need to keep track of the exact hours I work and how much I get paid.

This post was edited by JukeBOXX on Oct 2 2013 12:27pm
Go Back To Homework Help Topic List
Add Reply New Topic New Poll