• 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.

Luke =IF(OR(A5=16,AND(A5>=-10,A5

bobhc

Excel Ninja
Good day Luke

In a post earlier to day I posted this formula.. IF(A1>=10,A1,0)you then responded with =IF(OR(A5=16,AND(A5>=-10,A5<=10,A5<>-6)),A5,""). other than the obvious difference in cell names. I am slow in trying to understand what the extra code in your formula does, I realize this is not a collage course but could you point out the obvious to a learner
 
If a5=16

or

a5 is greater than or equal to -10 and less or equal to 10 and NOT EQUAL TO -6


then post a5

else nothing ""
 
Thanks Montrey.


@bobhc,

As Montrey explains, the way XL and VB handle the OR and AND operators is different. XL has you group all the arguments into one function (which, admittedly, is a little harder to read) while VB has you string the argument together(easier to read, but more typing). The other trick when reading the formula is seeing that the entire AND function is one of the arguments in the OR function. Does it make sense?
 
Good day gentlemen.

Many thanks for your explanations. I have a better understanding than half an hour ago.

I am one who needs pointing in the right direction to get were I need to be. I thank you both
 
yea with long formulas, If you paste it in excel and then go up to formulas bar and put ur cursor in the formulas bar and slowly move through the formula it becomes easier to read.


Also a must have to understanding formulas is to use the 'Evaluate Formula' tool under the tools menu---> formulas auditing--> evaluate formula.
 
Montrey

Thanks for the last post, will be able to try and understand formulas a bit better with the evaluate formula.
 
Back
Top