ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   help with time formula (https://www.excelbanter.com/excel-discussion-misc-queries/190083-help-time-formula.html)

cjbarron5

help with time formula
 
I have this formula =TEXT(D2-C2,"h:mm") but when d2 and c2 are empty it
displays 0:00 I think I can use =if(isna.........but I cant get the format
right
any ideas?
thanks

Bobt

help with time formula
 
Your best bet would be something like:

=IF(B7-B8=0,"Hello",TEXT(B7-B8,"h:mm"))

Of course, replace Hello with any text or value you want.

"cjbarron5" wrote:

I have this formula =TEXT(D2-C2,"h:mm") but when d2 and c2 are empty it
displays 0:00 I think I can use =if(isna.........but I cant get the format
right
any ideas?
thanks


ward376

help with time formula
 
Working with times and dates in Excel can seem complex, but what helps
me is thinking of them as numbers; dates to the left of the decimal
and times to the right. I just do whatever math I need to do and
format it when it's done.

Cliff Edwards


All times are GMT +1. The time now is 04:19 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com