soushinsha
soushinsha

Reputation: 83

Google sheet: if cell is Text || Null || Error || NaN || Empty || ISBLANK (do this), if cell is Number (do this)

on Google sheets how to do this?

If the cell c2 && d2 is: 
Text || Empty || Null || NaN || ISBLANK, 
show "invalid" on e2;
but, 
If both (c2 && d2) are numbers, 
show on e2 =SUM(c2*d2)

thank you.

Upvotes: 0

Views: 387

Answers (1)

a-burge
a-burge

Reputation: 1574

Put this in E2: =IF(AND(ISNUMBER(C2),ISNUMBER(D2)),C2*D2,"invalid")

Possibly suffices to have =IFERROR(C2*D2,"invalid") though, unless you're expecting blanks/null values.

Upvotes: 1

Related Questions