Method 1 – Apply Subtraction for Subtracting Military Time in Excel
Step 1:
- Select cell E5 to subtract military time.
- Use the following formula in the Formula Bar. The formula is,
=D5-C5
- D5 is the ending time, and C5 is the starting time of duties of the employees.
- Press Enter on your keyboard, and you will get 7:00 AM as the return of the subtraction formula.
Step 2:
- Auto Fill the subtract formula to the entire column, and you will get the output of the subtract formula that has been given in the screenshot below.
Step 3:
Look at our dataset; the formula returns military time with AM. We will convert these times into military time.
- From your Home tab, go to Number → More Number Formats
- After clicking on the More Number Formats option, a window named Format Cells will appear in front of you.
- From the Format Cells window, select Number.
- Select Time from the Category and select 37:30:55 from the Type box.
- Press OK.
- You will get the military time of the employees.
Method 2 – Use the MOD Function for Subtracting Military Time in Excel
Step 1:
- Select cell E5 to apply the MOD function.
- Type the MOD function in the Formula Bar. The formula is,
=MOD(D5-C5,1)
- Where D5-C5 is the time difference, and 1 is the divisor.
- Press Enter on your keyboard, and you will get 7:00:00 as the return of the MOD function in cell E5.
Step 2:
- Place your cursor on the bottom-right of cell E5, and an AutoFill sign will pop up.
- Drag the AutoFill sign down, and you will get your desired output.
Method 3 – Perform the Custom Format Command for Subtracting Military Time in Excel
Step 1:
- Select cells from E5 to E14, then press Ctrl + C on your keyboard.
- Select cell F5, right-click on it, and select Values from Paste Options.
- After pasting the values in column F from column E, you will get fraction values.
Step 2:
- Convert the fraction into military time. Right-click and select Format Cells.
- A window named Format Cells will instantly pop up.
- From the Format Cells window, select Number.
- Select Custom from the Category and select “hhmm” from the Type box.
- Press OK.
Here’s the result.
Things to Remember
You can press Ctrl + 1 simultaneously to pop up the Format Cells window instead of the Home ribbon.
Download the Practice Workbook
Related Articles
- How to Calculate Difference Between Two Times in Excel
- How to Calculate Time Difference in Numbers
- How to Calculate Time Difference in Minutes in Excel
- [Fixed!] VALUE Error (#VALUE!) When Subtracting Time in Excel
- How to Subtract and Display Negative Time in Excel
- How to Subtract Time and Convert to Number in Excel
- How to Subtract Date and Time in Excel
<< Go Back to Subtract Time | Calculate Time | Date-Time in Excel | Learn Excel
Get FREE Advanced Excel Exercises with Solutions!
If you are going to do military time don’t use AM / PM, did not help my issue of getting ###### in the calculation field.
Hello MARK,
To solve your ###### issue in the calculation field simply AutoFit the column width. You can AutoFit the column width like below screenshot.
Thank you for your comment.