Forum Discussion

kevans330's avatar
kevans330
Copper Contributor
Oct 22, 2020

Writing a formula to ignore a blank cell

I am working on a spread sheet and trying to get the formula to ignore a blank cell and do the calculation anyway: =IF(G22="","",IF(AND(G22>F22,AND(H22>F22),AND(I22>F22), AND(I22="")),ABS((G22-H22)/((G22+H22)/2)), "Value < MDLx5"))

 

The above formula is posted in J22, I need the formula to say if G22 is blank then leave blank otherwise perform ABS calculation above for G22, H22, I22. If I22 is blank I need to the calculation to still run but it will calculate G22 and H22. I am somewhat new to excel and have been working on this all day yesterday, any help on this would be greatly appreciated.

7 Replies

    • kevans330's avatar
      kevans330
      Copper Contributor

      HansVogelaar Hi, I hope you day is going well. I want to use a formula for the following:

      If cells G22, H22, and I22 are greater than the value in F22 then calculate in J22 (ABS((G22-H22)/((G22+H22)/2)) or else display "Value < MDLx5"). My issue is sometimes I22 may be left blank; in this circumstance I need the above calculation described for J22 to happen accept it would be for G22 and H22 (I just need it to ignore I22 if left blank but still perform the calculation.

      on a side note I need J22 (where the formula would be) to be blank if G22 is blank (I don't know if we can fit that in the formula somewhere). I hope this helps, thank you for taking the time to look at this for me.

      • HansVogelaar's avatar
        HansVogelaar
        MVP

        kevans330 

        How about

         

        =IF(G22="","",IF(AND(G22>F22,H22>F22,OR(I22>F22,I22="")),ABS((G22-H22)/((G22+H22)/2)),"Value < MDLx5"))

Resources