Forum Discussion

Jamesb1982's avatar
Jamesb1982
Copper Contributor
Jul 05, 2023

Excel formula Help

Hey Guys. 

 

I'm using a formula of =E445 + IF((G445 = "Yes "), 28, 14) to calcuate a date. 

However, when either E445 or G445 are blank its giving a value of 14/01/1900. 

 

Any idea how if the entry is blank the response will be blank until data is entered?

 

Thanks

  • Mike_Y_123's avatar
    Mike_Y_123
    Copper Contributor

    Jamesb1982 

     

    I would first check if both of the cells are not blanks.

    Then if the cells have data in them, perform your formula.

     

    If 1 or both cells are blank then "Missing data" is displayed....

    =If(AND(not(ISBLANK(E445)),not(ISBLANK(G445))),   E445+IF((G445 = "Yes "), 28, 14)   ,"Missing data")

     

    If 1 or both cells are blank then a blank (or "") is displayed....

    =If(AND(not(ISBLANK(E445)),not(ISBLANK(G445))),   E445+IF((G445 = "Yes "), 28, 14)   ,"")

     

    Hope this helps, please mark it as the answer if it does

    Thanks

Resources