View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Radrays Radrays is offline
external usenet poster
 
Posts: 14
Default Nested IF formula question

I am currently using the formula below to calculate difference in dates in
Excel 2003 where C4 = start date and D4 = completion date. How can I
suppress any "0" in the responses. For example if the result is only 21 days
then I do not want to show 0 years , 0 months. I will always want to show
days.

=DATEDIF(C4,D4,"y")&" years, "& DATEDIF(C4,D4,"ym")&" months, "&
DATEDIF(C4,D4,"md")&" days"

Thank you for your time.
--
Radrays