+ Reply to Thread
Results 1 to 3 of 3

I have two parts of a formula figured out but can't figure out how to put it together.

  1. #1
    Registered User
    Join Date
    04-13-2017
    Location
    Dallas
    MS-Off Ver
    2016
    Posts
    13

    Question I have two parts of a formula figured out but can't figure out how to put it together.

    I have a cell (G9) that I want to populate as "FAIL" if cells K2 through K6 return the word "FAIL", "PASS" if not. And "FAIL" if cells N4 through N8 have a less than more than factor that gives a pass fail in G9.

    This part works:
    =IF(COUNTIF(K2:K6,"FAIL"),"FAIL","PASS")

    This also works:
    =IF(AND(N4>0,N4<33),"FAIL","PASS")

    However, if I add anything to it, it fails.
    =IF(SUM(N4>0,N4<33),"FAIL",(N5>0,N5<33),"FAIL",(N6>0,N6<32),"FAIL",(N7>0,N7<30),"FAIL",(N8>0,N8<20),"FAIL","PASS"))

    N4 and N5 have the same <>, N6 is <32, N7 is <30, N8 is <20.

    Please help, I have spent a couple of hours on this and I know my boss is about to get irritated with me on long this is taking me.

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,199

    Re: I have two parts of a formula figured out but can't figure out how to put it together.

    Try

    =IF(OR(AND(N4>0,N4<33),AND(N5>0,N5<33),AND(N6>0,N6<32),AND(N7>0,N7<30),AND(N8>0,N8<20)),"FAIL","PASS")

  3. #3
    Registered User
    Join Date
    04-13-2017
    Location
    Dallas
    MS-Off Ver
    2016
    Posts
    13

    Re: I have two parts of a formula figured out but can't figure out how to put it together.

    You are so awesome! Thanks!

    I combined the two like this and it works like a dream!

    =IF(OR(COUNTIF(K2:K6,"FAIL"),AND(N4>0,N4<33),AND(N5>0,N5<33),AND(N6>0,N6<32),AND(N7>0,N7<30),AND(N8>0,N8<20)),"FAIL","PASS")

    Thank you again!

+ 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. Replies: 4
    Last Post: 02-03-2014, 08:05 AM
  2. Sum formula to exclude monthly budget figure when actual figure is entered
    By rocketmail in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-02-2013, 04:22 AM
  3. Replies: 5
    Last Post: 01-18-2013, 11:21 AM
  4. nm, figured it out
    By justin111 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-19-2010, 05:53 PM
  5. Figured out my Boston Problem
    By preferiti in forum Excel General
    Replies: 0
    Last Post: 04-24-2009, 01:15 AM
  6. Still haven't figured this one out
    By mevetts in forum Excel General
    Replies: 7
    Last Post: 01-03-2006, 06:11 AM
  7. HELP!!! Can't get forumla figured out!
    By JTKrupa in forum Excel General
    Replies: 8
    Last Post: 10-13-2005, 05:13 PM

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