Jun 19 2019 11:29 AM
in cell E2, i have a Vlookup: =VLOOKUP($C:$C,'Vlookup Scott'!$C$2:$K$10,3,FALSE)
and i need to run a If(OR(AND statement in cell Q2: =IF(OR(AND(E2="R",F2=8.25,P2<=1.4,P2>=1.2),AND(E2="R",F2=9.5,P2<=1.6,P2>=1.2),AND(E2="P",F2=8.25,P2<=1.5,P2>=1.3),AND(E2="P",F2=9.5,P2<=1.7,P2>=1.3)),"PASS","FAIL")
it will only work when i have E2 as a regular text cell. is there a way to run Q2 with the vlookup in E2?
Jun 19 2019 11:41 AM
What does your VLOOKUP return? It shall work as
=VLOOKUP($C$1,'Vlookup Scott'!$C$2:$K$10,3,FALSE)
taking first element from C:C to lookup.
Another point perhaps in your range not exact text as "R" but something like "R ", you may check manually.
In general it doesn't matter for your second formula how the value in E2 appeared, by formula or added manually.
Jun 19 2019 11:43 AM
the Vlookup brings back what i need it to, but the IF(OR(AND does not. it looks like it only works when i enter it manually.
Jun 19 2019 12:31 PM
I think i have it. it wasn't reading the numbers as numbers, and instead read them as a text statement off of the vlookup.
Jun 19 2019 01:11 PM
Okay, so far so good. I didn't catch why numbers since in your OR formula you compare E2 with texts as "R" and "P". But that doesn't matter if finally it works.