• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

see if all values in a column are same

Rodger

Member
this is so simple, sorry, but I am doing something wrong
what I need:
I have a column of true/false - if all in the column are false, it returns ''x''
if one or more are true, it returns ''(blank)''

I am using
=COUNTIF(AC!$R$39:$R$52,"<>FALSE")=1

this only accounts if one is different, I need to know if all are FALSE ''x'' or if any or all are TRUE
 
=COUNTIF(AC!$R$39:$R$52,"<>FALSE")=counta(AC!$R$39:$R$52)
that will count the rows in the range AC!$R$39:$R$52 and so you know the total number of rows
Then ALL are false

I may be over complicating this

=IF(OR(COUNTIF(AC!$R$39:$R$52,"<>"&FALSE)=COUNTA(AC!$R$39:$R$52),COUNTIF(AC!$R$39:$R$52,"<>"&TRUE)=COUNTA(AC!$R$39:$R$52)),"X", "Not all TRUE OR FALSE")

if you just need an X if all TRUE - OR all FALSE

A small example on the same sheet - just to see it in action
 

Attachments

  • count all TRUE or FALSE.xlsx
    8.8 KB · Views: 0
Another idea. Since your column comprises Booleans
Code:
= IF( OR(Table1[Booleans]), "", "x" )
will first evaluate to TRUE if any entry is TRUE and then turns TRUE to "" or FALSE to "x".
Note: I have only used an Excel Table because I dislike the default practice of direct cell referencing.
 
Back
Top