L Rogers
L Rogers

Reputation: 79

IF AND Statement

I have the following If statement which is working the way I want it too.

However I need to add an extra condition where IF C7 has no data in it then it will show as 0. At the moment the cell the formula is in is showing #VALUE.

I think that I will need to use IF(AND however my attempts have failed me.

=IF(C6="BT",12.88+(C7-30)*0.6,IF(C7<35,4.3,4.3+(C7-35)*0.2))

Thanks

Upvotes: 1

Views: 42

Answers (1)

LJ01
LJ01

Reputation: 589

You could check for blanks first.

=If(c7="",0,IF(C6="BT",12.88+(C7-30)*0.6,IF(C7<35,4.3,4.3+(C7-35)*0.2)))

I just thought to add another approach I often use because I think it makes it easy to read is;

=If(c7="",0,1)*IF(C6="BT",12.88+(C7-30)*0.6,IF(C7<35,4.3,4.3+(C7-35)*0.2))

And there's another to skin this cat...

=Iferror(IF(C6="BT",12.88+(C7-30)*0.6,IF(C7<35,4.3,4.3+(C7-35)*0.2)),0)

Upvotes: 2

Related Questions