SOLVED

# IF -Isblank function to check two cells are blank

Occasional Contributor

# IF -Isblank function to check two cells are blank

Hi

I was putting a formula in column P

=IF(ISBLANK(M3),K3*N3,M3*N3)+O3 which checks if there is any value is there in column M and takes the rest calculation if M is blank... and if there is no value in M & K it returns 0.

If both M and K columns are blank I wish to get the value in P as blank... I don't want 0 to appear

Is there any possible way ….. Please guide...

8 Replies

# Re: IF -Isblank function to check two cells are blank

As variant

=IF(ISBLANK(M3)*ISBLANK(K3),"",O3+(K3*ISBLANK(M3)+M3)*N3)

best response confirmed by pillaisg (Occasional Contributor)
Solution

# Re: IF -Isblank function to check two cells are blank

Exactly what I needed.

Thanks@Sergei Baklan

# Re: IF -Isblank function to check two cells are blank

If both K3 and M3 are blank we return empty string. Just in case

ISBLANK(M3)*ISBLANK(K3)

is equivalent of

AND(ISBLANK(M3),ISBLANK(K3))

since in calculations TRUE is converted to 1 and FALSE to zero.

In second part

(K3*ISBLANK(M3)+M3)

if M3 is blank that will be

(K3*1+0)          or simply K3

if M3 is not blank that will be

(K3*0+M3)      or simply M3

Thank you for marking as accepted solution, but better to move Best response on answer itself.

# Re: IF -Isblank function to check two cells are blank

Thanks it was of great help.

Thanks @Sergei Baklan

# Re: IF -Isblank function to check two cells are blank

@pillaisg , you are welcome

# Re: IF -Isblank function to check two cells are blank

I hv 5 cell in excel A,B,C,D & E
IF C,D,E BLANK THEN B-A
IF D&E BLANK C-A
IF E&C BLANK D-A
IF C&D BLANK E-A

I am trying to write formula since Sundays but fail kindly help me to write this formula in excel

# Re: IF -Isblank function to check two cells are blank

In a cell in row 2, for example in F2:

=IFS(AND(C2="",D2="",E2=""),B2-A2,AND(D2="",E2=""),C2-A2,AND(C2="",E2=""),D2-A2,AND(C2="",D2=""),E2-A2,TRUE,"None of these")

# Re: IF -Isblank function to check two cells are blank

Perhaps

=LOOKUP(2, 1/(A2:E2<>""), A2:E2)-A2