Crosswords20 mins ago
Excel and timesheets
what do i need to do to be able to get a spreadsheet which works out the hours i have worked each day. If i put the start time in the first column, end time in the second column, what formula should go in the third to work out the hours worked?
the reason i ask is that i need to find out hours worked each day for the past 5 months and this would make it so much easier.
Answers
No best answer has yet been selected by CiderMonkey. Once a best answer has been selected, it will be shown here.
For more on marking an answer as the "Best Answer", please visit our FAQ.Recently did this, and had a hell of a job getting it to work. The following works, but may not be the most elegant solution (and assumes a start and finish on the same day):
Format your "Start" column (A) as "time", enter the time in the 24hr clock, including a colon to seperate the hours (eg 08:00) - it will automatically add :00 seconds.
Format your "Lunch" column (B) as "general", and enter your break as minutes (eg 30 for a half-hour lunch).
Format your "Finish" column (C) as "time", enter the time in the 24hr clock as column A.
Format your "hours worked" column (D) as a two decimal point number.
The formula for column D, row 1 is =(((C1-A1)*1440)-B1)/60.
The multiplication converts the result of subtracting your start time from your end time into minutes, allowing you to subtract the minutes you took for lunch; and the division converts the result back to hours.
Hi - in the example you give you have worked 1 hour 40 minutes, ie 1 and 2/3rd hours or 1.666666666 etc which rounds up to 1.67 hours. If you'd rather use hours:minutes, try this:
Change the format of column D to "Custom" and select hh:mm. Change the formula to =(C1-A1)-(B1/1440). I've just tested it, and that seems to work.
If you have been totalling your hours with a sum [say =SUM(D1:X1)], you will need to change the format of the appropriate cell to Custom/hh:mm as well!
1440 is the number of minutes in a day (60*24). I think it's necessary because of the way the cells are formatted in my example - not quite sure why, but it's got something to do with the way Excel performs time calculations.
Like I said, there are probably more elegant ways to do it, but I know my way works!
Related Questions
Sorry, we can't find any related questions. Try using the search bar at the top of the page to search for some keywords, or choose a topic and submit your own question.