Cell contains only 1 value

Benong

New Member
Joined
Mar 18, 2024
Messages
10
Office Version
  1. 365
Platform
  1. Windows
Hi,
How to check if a cell contains the same value (at least 3 values) on the same row across multiple columns?
Col A. Col B. Col C Col D
Car. Plane. Kettle Dog
1,1,1,1 0,0,0,0,0,0 1,0,11,0,0 1,1

Ans: Car, Plane (return values)
 
Col A
Car
1,1,1,1

Col B
Plane
0,0,0,0,0,0

Col C
Kettle
1,1,1,1 0,1,0,11,0,0

Col D
Dog
1,1
 
Upvote 0
It's unclear on your data structure. Like this?
Book1
ABCD
1CarPlaneKettleDog
21011
31011
4101
5101
600
71
80
91
101
110
120
Sheet5
 
Upvote 0
Or is it like this:

Book1
ABCDEFG
1CarPlaneKettleDogCarPlane
21,1,1,10,0,0,0,01,1,1,1,0,1,0,1,1,0,01,1
Sheet1
Cell Formulas
RangeFormula
F1:G1F1=FILTER(A1:D1,(ISNUMBER(FIND("1,1,1",A2:D2)))*ISERROR((FIND("0",A2:D2)))+(ISNUMBER(FIND("0,0,0",A2:D2))*ISERROR(FIND("1",A2:D2))))
Dynamic array formulas.
 
Upvote 0
Or is it like this:

Book1
ABCDEFG
1CarPlaneKettleDogCarPlane
21,1,1,10,0,0,0,01,1,1,1,0,1,0,1,1,0,01,1
Sheet1
Cell Formulas
RangeFormula
F1:G1F1=FILTER(A1:D1,(ISNUMBER(FIND("1,1,1",A2:D2)))*ISERROR((FIND("0",A2:D2)))+(ISNUMBER(FIND("0,0,0",A2:D2))*ISERROR(FIND("1",A2:D2))))
Dynamic array formulas.
This is the structure. It works on one row only. can expand formula to include more rows?
 
Upvote 0
Assuming only 0s and 1s like your sample, or at least only single-digit values, possibly this formula in F2, copied down?

25 02 24.xlsm
ABCDEFGHI
1CarPlaneKettleDog
21,1,1,10,0,0,0,01,1,1,1,0,1,0,1,1,0,01,1CarPlane
30,00,00,00,0 
4 
50,0,0,10,0,01,1,1,1,1,10,0,0,0PlaneKettleDog
60,0,00,0,00,0,00,0,0CarPlaneKettleDog
70,0,0,10,0,0,11,1,1,1,1,10,0,0,1Kettle
Same value
Cell Formulas
RangeFormula
F2:G2,F6:I6,F5:H5,F3:F4,F7F2=FILTER(A$1:D$1,(SUBSTITUTE(A2:D2&",",LEFT(A2:D2,2),"")="")*(LEN(A2:D2)>4),"")
Dynamic array formulas.
 
Upvote 0
Solution

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