» Calculating Absolute Difference between Two Time Values
CATEGORY - Excel Date & Time Formulas
VERSION - All Microsoft Excel Versions
Columns A & B contain pairs of time values from the same day.
We want to create a formula that always subtracts the earlier time from the later one, regardless of which column each is in.
Solution 1:
Use the IF function as shown in the following formula:
=IF(B2>=A2,B2-A2,A2-B2)
Solution 2:
Use the ABS function as shown in the following formula:
=ABS(B2-A2)
Note: Apply hh:mm format to cells containing the formulas.
Book Store:
Recommended Books:
- Cashflow Quadrant: Rich Dad's Guide to Financial Freedom
- F1 Get the Most out of Excel! The Ultimate Excel tip Help Guide
- Who Moved My Cheese? An Amazing Way to Deal with Change in Your Work and in Your Life
- Seven Habits Of Highly Effective People
- Managing by the Numbers: A Commonsense Guide to Understanding and Using Your Company's Financials: An Essential Resource for Growing Businesses
- Adventure Capitalist: The Ultimate Road Trip
business days
Ghulam Sarwar
How I do calculate day if our org has 22 days in a month?
another formula
shawn
IF(B2>=A2,B2-A2,24-A2+B2)


any suggestion is highly appreciated thanks a lot