+ Reply to Thread
Results 1 to 6 of 6

How to combine OR and AND when referring to same cell

  1. #1
    Registered User
    Join Date
    10-02-2012
    Location
    Bangalore
    MS-Off Ver
    Excel 2016 / Office: 365
    Posts
    37

    How to combine OR and AND when referring to same cell

    Hi Experts,

    please can you help me with this formula & what is the logic error in this

    IF(OR(G2<>"",AND(G2<>"No",D2>8000)),E2,"") -- > Does not work when G2 is Null or G2 is NO


    IF((OR(G2<>"No", G2<>"",AND(D5>8000))),F2,"") -->Does not work when G2 is Null or G2 is NO

    I have attached the sample sheet. Your help would be appreciated.



    Thanks a ton
    Attached Files Attached Files

  2. #2
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,466

    Re: How to combine OR and AND when referring to same cell

    Do you mean F2=E2 only if both criterias meet?

    =IF(AND(G2="Yes",D2>8000),E2,"")
    Quang PT

  3. #3
    Registered User
    Join Date
    10-02-2012
    Location
    Bangalore
    MS-Off Ver
    Excel 2016 / Office: 365
    Posts
    37

    Re: How to combine OR and AND when referring to same cell

    Thank you @bebo021999
    for the response.


    This is what I want:
    When Status(Column G) is NOT Blank OR NO, and Sales > 8000 then I want Result(Column E) to be displayed else Blank
    I could say Status is YES but I have 8 states in my data file. So using NOT logic.
    Is this possible ?

    Thanks in Advance

  4. #4
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,081

    Re: How to combine OR and AND when referring to same cell

    Maybe
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    10-02-2012
    Location
    Bangalore
    MS-Off Ver
    Excel 2016 / Office: 365
    Posts
    37

    Re: How to combine OR and AND when referring to same cell

    Quote Originally Posted by Fluff13 View Post
    Maybe
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Thank you very much @Fluff13, This really works on my sample file as expected. I will try this on my data file tomorrow.
    Please have a great day. Thank you @Fluff13 and @Bebo021999

  6. #6
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,081

    Re: How to combine OR and AND when referring to same cell

    You're welcome & thanks for the feedback.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Referring to a cell...
    By ChrisXcel in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-12-2020, 12:02 AM
  2. [SOLVED] Referring to the second matching cell
    By spark.tsang in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 05-29-2019, 12:29 PM
  3. Referring a cell to a pdf
    By tomlannom in forum Excel General
    Replies: 2
    Last Post: 09-14-2017, 12:19 PM
  4. Formula referring to cell above
    By ChrisXcel in forum Excel General
    Replies: 3
    Last Post: 04-02-2014, 01:34 AM
  5. [SOLVED] VBA referring to a different sheet, automatically fill cell based on content of other cell
    By mweick in forum Excel Programming / VBA / Macros
    Replies: 27
    Last Post: 02-06-2013, 11:50 AM
  6. Cell Referring to Itself
    By Crisi88 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 06-04-2010, 04:11 PM
  7. Validation - Referring to the cell above
    By lolainlondon in forum Excel General
    Replies: 2
    Last Post: 01-22-2008, 10:06 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1