working out rota hours

prgray77

New Member
Joined
Jul 13, 2014
Messages
4
hi, i am making a rota where on a given day the days hours are entered in as 7 - 3 which is 7 am to 3 pm is there a way i can get excel to return a value in the next cell as the number of hours worked as in this case 8 hours
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
"03:00:00 PM"-"07:00:00 AM" would work.
If you have a cell that shows the start time, Link that cell to the "07:00:00 AM" and link end time to "03:00:00 PM"
Assuming your start time is in A1 and end time is B1 the formula would be.
B1-A1 then if the times change the total hours will still pick up on it.
 
Upvote 0
Assuming in A1 you have 7 - 3 i.e "7" + space + "-" space + "3"

Then Try

=RIGHT(A1,2)+12-LEFT(A1,2)
 
Upvote 0

Forum statistics

Threads
1,217,127
Messages
6,134,775
Members
449,888
Latest member
webarnes99

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top