Can a formula do this?

weegieavlover

Board Regular
Joined
Aug 13, 2010
Messages
64
I need a formula that is in a cell to be able to insert a 1 or 0 in another cell - is that possible:

What I need is a formula that does this:

if column a1:a10 = x
AND
if column b1:b10 = y
THEN
insert "0" in column c1:c10 (where the match is)
IF NOT
insert "1" in column c1:c10 (where there is no match)

Hopefully that makes sense.

Regards
Colin
 
Any suggestions?

the formula in Column I:

=ISNUMBER(MATCH(G1,A1:A10,0))*ISNUMBER(MATCH(H1,B1:B10,0))

Is there anyway to get this formula to insert the 1 or 0 into column C.

Why don't you try the formula as given to you?

Enter in C1 and apply control+shift+enter:

=ISNUMBER(MATCH(1,IF($A$1:$A$10=G1,IF($B$1:$B$10=H1,1)),0))+0

Control+shift+enter: Press the control and shift key while you hit enter.
 
Upvote 0

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Unless i have missed something putting the formula in C instead of I would work or in C1 put =I1 etc.

Or is there something more subtle at work here?
 
Upvote 0
Enter in C1 and apply control+shift+enter:

=ISNUMBER(MATCH(1,IF($A$1:$A$10=G1,IF($B$1:$B$10=H1,1)),0))+0

Control+shift+enter: Press the control and shift key while you hit enter.
Array entered**:

=MAX(IF($A$1:$A$10=G1,IF($B$1:$B$10=H1,1)))

** array formulas need to be entered using the key combination of CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the SHIFT key then hit ENTER.
 
Upvote 0

Forum statistics

Threads
1,214,622
Messages
6,120,572
Members
448,972
Latest member
Shantanu2024

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