ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Array gives wrong answer (https://www.excelbanter.com/excel-discussion-misc-queries/118436-array-gives-wrong-answer.html)

Shu of AZ

Array gives wrong answer
 
in an adjacent cell i'm attempting to indicate whether or not any of the
first four numbers in H,G,I and J, are present in either K, N, O, or P and
indicate that by displaying a 1. The formual now indicates True by
displaying a 1 yet the formual should indicate False by representing a 0. Is
it the use of commas between the cell designations that is causing this? If
so, what is the character I should be using. It works well with the use of a
: to represent a range but once I add in one lone cell such as the K4, it
does not work. Any ideas?


H G I J K L M N O P
Row4 7 9 3 1 7 3 3 3 3 1

{=--AND(OR(G4=K4,L4,O4,P4),OR(H4=K4,L4,O4,P4),OR(I4=K4 ,L4,O4,P4),OR(J4=K4,L4,O4,P4))}

Bob Phillips

Array gives wrong answer
 
It's not an array formula

=--(OR(OR(G4=K4,G4=L4,G4=O4,G4=P4),OR(H4=K4,H4=L4,H4= O4,H4=P4),OR(I4=K4,I4=L
4,I4=O4),OR(I4=P4,J4=K4,J4=L4,J4=O4,J4=P4)))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"Shu of AZ" wrote in message
...
in an adjacent cell i'm attempting to indicate whether or not any of the
first four numbers in H,G,I and J, are present in either K, N, O, or P and
indicate that by displaying a 1. The formual now indicates True by
displaying a 1 yet the formual should indicate False by representing a 0.

Is
it the use of commas between the cell designations that is causing this?

If
so, what is the character I should be using. It works well with the use

of a
: to represent a range but once I add in one lone cell such as the K4, it
does not work. Any ideas?


H G I J K L M N O P
Row4 7 9 3 1 7 3 3 3 3 1


{=--AND(OR(G4=K4,L4,O4,P4),OR(H4=K4,L4,O4,P4),OR(I4=K4 ,L4,O4,P4),OR(J4=K4,L4
,O4,P4))}




All times are GMT +1. The time now is 04:49 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com