Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
As with so many posts on this group, you haven't included enough detail in
the question, nor does your example make it clear. How do you do the rounding at each end of the working day? To units of an hour, or half an hour, or a quarter of an hour? Do you round to the nearest unit, or does the employee always lose out on the rounding at each end of the working day? Do you want a result as an Excel time, or as decimal hours? [In other words, would you want 8:30 or 8.5?] Can the time worked span midnight? Do you need the formula to return a blank in cases where you haven't yet filled in times for IN and OUT? Once you've sorted out the question, the answer will probably be relatively easy. Making a guess at some of the answers, you may want something like: =IF(OR(B2="",C2=""),"",FLOOR(C2*24,0.25)-CEILING(B2*24,0.25)) -- David Biddulph "yclhk" wrote in message ... I'd like to create a excel file to calculate the hours worked. Col A Col B Col C Col D Date Time IN Time OUT hrs worked in col B, record Time IN 7:53am in col C, record Time OUT 6:05pm However, 7:53am expects to count as 8:00am & 6:05pm count as 6:00pm, and hours worked results as 10 hours I wish to keep the records of the Time IN & OUT in the actual time and how to set the formula to calculate in form of the expected result in col D ? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Converting a time format to a String format in Excel | Excel Discussion (Misc queries) | |||
Custom Cell format to mimic time format | Excel Discussion (Misc queries) | |||
convert time imported as text to time format for calculations | Excel Worksheet Functions | |||
How to format cells in Excel for time in format mm:ss.00 | Excel Worksheet Functions | |||
Remove time from a date and time field? Format removes the displa. | Excel Worksheet Functions |