Forum Discussion
GaryGiles
Oct 23, 2022Copper Contributor
How to use the IF function when part of the data is a time?
I am trying to build a spreadsheet that builds a cost each day from some power usage of a piece of equipment. I therefore have two columns of when the equipment starts and when it stops. It only runs...
HansVogelaar
Oct 23, 2022MVP
The columns are formatted to display the time, but what do you see in the formula bar when you select one of the cells? Just the time, or the date plus the time?
GaryGiles
Oct 23, 2022Copper Contributor
Just the time in the formula bar - formatted as 00:00:00.
- HansVogelaarOct 23, 2022MVP
See the attached demo workbook. Column G contains formulas that should work in all versions of Excel; column H contains formulas that are more readable but work only in Office 2021/Microsoft 365.