Function which handles numerous variables

W

Working Jane

I want a formula to make another evaluation based on answer to the previous
evaluation(s); i.e. if answer to 1 is 0, then do next eval; if answer to
second eval is 1, then do next eval and so on. It should stop at whatever
eval gives the desired result before defaulting to "do nothing" (""). Years
ago I could use the OR function to do this, now OR is inadequate. Nested IF
functions can get too cumbersome (if FALSE do this, if TRUE do that for each
evaluation). Likewise with VLOOKUP or HLOOKUP. Would like a suggestion, for
example, "IF(ISBLANK(A1),C1,OR IF(A1>B1,A1-B1,OR IF(A1<B1,B1+C1),OR
IF(A1=B1,B1),"")." Need something like the old OR function, which was good
for evaluating a large range of variables not necessarily in a table and in
search of a specific value(s). Hoping for a new or better or other function
in Excel that I'm not aware of, or just a new perspective on how to better
use an existing function. I do these types of evals often at work and the
build on successive IFs can take hours to perfect or stop the input at "too
many variables."
 
B

Bernard Liengme

Not sure what you want but this has syntax errors:
IF(ISBLANK(A1),C1,OR IF(A1>B1,A1-B1,OR IF(A1<B1,B1+C1),OR IF(A1=B1,B1),"")
Try
=IF(ISBLANK(A1),C1,IF(A1>B1,A1-B1,IF(A1<B1,B1+C1,IF(A1=B1,B1,""))))

The syntax of IF with two nestings is: IF(condition_1,
true_answer,IF(condition_2,true_answer, false_answer)
This of IF..ELSE rather than IF..OR

OR is used like this: =IF(OR(A1<3,A1>10),"A1 is out of range","A1 is within
3-10")

best wishes
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top