1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Formula with Negative Values

Discussion in 'Business Applications' started by twannusa, Dec 2, 2009.

Thread Status:
Not open for further replies.
Advertisement
  1. twannusa

    twannusa Thread Starter

    Joined:
    Dec 2, 2009
    Messages:
    1
    I need a formula that when value X is between, say 6 and -6, the result is True (or Pass) and when it is not within that range it is False (or Failed). If possible, I would like for this formula to be in one cell. Is this possible when there is a negative number in the formula? Here is what I have tried:

    =IF(6>E14>-6, "Pass","Failed")

    However, Excel does not appear to recognize the "-" in the formula as negative.

    Thanks,
    Twannusa
     
  2. slurpee55

    slurpee55

    Joined:
    Oct 20, 2004
    Messages:
    7,837
    Without thinking about it much, just add 6 to each portion
    =IF(AND(E14+6>0,12>E14+6),"Pass","Failed")
     
  3. The Villan

    The Villan

    Joined:
    Feb 20, 2006
    Messages:
    2,255
    It should be this

    =IF(AND(E14>=-6,E14<=6),"Pass","Failed")
     
  4. bomb #21

    bomb #21

    Joined:
    Jul 1, 2005
    Messages:
    8,546
    Just for fun, you could use ABS (short for ABSOLUTE) to "override" the sign:

    =IF(ABS(E14)<=6,"Pass","Failed")
     
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/882303

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice