IF range contains a value then....

bob33

Board Regular
Joined
Oct 28, 2011
Messages
59
Sorry, I'm fried. Likely easy.

I need to look in a range of cells for the value 1 and if there, then 1, otherwise 0.
I thought this would work but doesn't:
=IF(C$48:C$51=1,1,0)

Thanks!
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
it would work if you entered it as an array formula. instead of pressing enter when you type the formula press cntrl+shift+enter
 
Upvote 0
Sorry, I'm fried. Likely easy.

I need to look in a range of cells for the value 1 and if there, then 1, otherwise 0.
I thought this would work but doesn't:
=IF(C$48:C$51=1,1,0)

Thanks!

You need to clarify what you want. Your formula works fine based on what you said you want to do...

If there is a "1" in any cell from C48:51.... then a 1 will be displayed in the cell you entered your "IF". Works perfectly.
 
Upvote 0
I apologize for slow reply!
I ended up using: =IF(AND(C$54=0,C$55=1),1,IF(C49=0,0,1))
which obviously far from my original issue.
Simon4s: It still doesn't work. On my screen now are 2 1s in that range and the value for the formula is 0 (entered as an array formula).

Everyone else: I appreciate your suggestions; I learned some new approaches to the same issue, always a plus!
 
Upvote 0

Forum statistics

Threads
1,214,983
Messages
6,122,595
Members
449,089
Latest member
Motoracer88

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.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

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

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

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
Back
Top