Using the IF function for dates

Solved/Closed
courtney - Dec 15, 2015 at 10:48 AM
 RayH - Dec 15, 2015 at 12:49 PM
Hello,

I am trying to figure out in Microsoft excel 2010 the appropriate IF formula to use. I am trying to calculate the number of working days that I have from Column A to Column B However if Column B is empty I would like the formula to use the date in Column C. If both Columns are empty then I would like for the formula to leave the cell Blank.

Any tips on how to do this would be greatly appreciated.



Related:

1 response

This uses the Excel function NETWORKDAYS to return the number of working days.

=IF(NOT(ISBLANK(B1)),NETWORKDAYS(A1,B1),IF(NOT(ISBLANK(C1)),NETWORKDAYS(A1,C1),""))
3