Interval between 2 times in Excel

For example, I want to find the number of hours that employees have logged in office based on "In Time" and "Out Time".

To do it in Excel, here is the answer:

a) Enter the formula subtracting In Time from Out Time (in the example below, AC3-AB3 since AC3 has Out time and AB3 has In Time).

The value returned is a serial number equivalent of time difference between Out Time and In Time.

excel interval between 2 times

b) To get the result in hours and minutes format, right click on the cell with results, click on Format Cells.

excel interval between 2 times

c) Select "Custom" under "Number" tab and then in "type" field, enter "h:mm" to display results in hours and minutes.

excel interval between 2 times

d) Copy the formula for the rest of the rows.

excel interval between 2 times

 

You can find similar Excel Questions and Answer hereunder

1) How do you know which column was used last, Here the explanation to find it with VBA

2) How can I add interval to dates?

3) How can I find the number of working days between 2 dates using VBA?

4) How to protect your workbook in Excel

5) How to modify strings in VBA, what are the functions you can manipulate strings with

6) Vba code to password protect workbook in Excel

7) I have 2 sets of lists from 2 different reports - how can I select the cells with differences?

8) I have test scores for my student population. In Excel, how can I determine confidence interval for my Population Mean?

9) How do I disable the right click option for users in my WorkBook?

10) Find and count instances of a character in a string in Excel

 

Here the previous and next chapter