# 2 IF statements in the same cell

#### pink

##### New Member
'IF(AND(OR(L9=1,L9=2),OR(M9=3,M9=4)),Sheet1!\$D\$32, IF(AND(OR(L9=3,L9=4),OR(M9=1,M9=2)),Sheet1!\$D\$33, IF(OR(M9=3,M9=4),Sheet1!\$D\$33,0)))'

This is my original formula, it works, but I also need to include another completely unrelated IF statement that says

'IF(OR(M9=3,M9=4), Sheet1!\$D\$32,0)'

This formula also works, but I need them to work together and independantly, in the same cell. If the second statement is true, I still need it to check if the first one is true, and to add the values together.

Is there any way to do that?

Thanks.

### Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.

#### tactps

##### Well-known Member
It sounds like you just want to add them:

=IF(AND(OR(L9=1,L9=2),OR(M9=3,M9=4)),Sheet1!\$D\$32, IF(AND(OR(L9=3,L9=4),OR(M9=1,M9=2)),Sheet1!\$D\$33, IF(OR(M9=3,M9=4),Sheet1!\$D\$33,0)))+IF(OR(M9=3,M9=4), Sheet1!\$D\$32,0)

Is that what you want?

#### pink

##### New Member
Yes, that worked, thank you. I didn't realize you could do that.

Replies
6
Views
275
Replies
9
Views
273
Replies
1
Views
158
Replies
2
Views
230
Replies
3
Views
316

1,148,396
Messages
5,746,452
Members
424,020
Latest member
LongDoo

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back