To calculate the working hrs of employee in excel

P

pol

I have an excel sheet with opening hrs and closing hrs of the business . Then
Inhave to find out the working hrs.

A1 cell contain opeining hrs and B1 cell contain closing cell

A1 cell value = 8.50 AM
B1 Cell value = 17.40 PM.

Please hw I can find out the working hrs as 8.40 .

with thanks and regards
Pol
 
D

David Biddulph

Firstly, use 8:50 (with a colon) instead of 8.50 (with a full stop)
Secondly, use either 17:40 (24 hour clock) or 5:40 PM (12 hour clock)
Thirdly, if you are using the 12 hour clock, use one (and only one) space
between the 5:40 and the PM, not 2 spaces as you have
If you deal with those, =B1-A1 will give you 8:50
If you want 8:40, you'll need to subtract 10 minutes, so =B1-A1-TIME(0,10,0)
You could, of course, devise a formula to correct some of the errors above,
but you'll need to know what range of possible errors you are trying to deal
with.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top