Assigning Hours/Minutes to a Cell

Barber_91

Board Regular
Joined
Feb 13, 2004
Messages
72
I have a formula that says:

If cell A2 (date/time) is blank, and cell B2 (date/time) is blank, assign "24:00" to cell C2.
It works fine, but it treats my 24:00 as text (understandably so).

Is there a way to assign the value of 24hrs to the cell in C2 so that Excel treats it as time?

The way it is now, I can't add up all the values in C2 because Excel treats the values as text. I want to be able to add all the 24:00 together so I can arrive at a total.
 

Some videos you may like

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.

Watch MrExcel Video

Forum statistics

Threads
1,114,636
Messages
5,549,103
Members
410,897
Latest member
Ekrupa25
Top