+ Reply to Thread
Results 1 to 6 of 6

IF and Formula Help

  1. #1
    Registered User
    Join Date
    02-23-2022
    Location
    England
    MS-Off Ver
    Excel 365
    Posts
    4

    IF and Formula Help

    =IF(AND(F3>=N9,F3<=N10),N12,N13),IF(AND(F3>=P9,F3<=P10),P12,P13),IF(AND(F3>=R9,F3<=R10),R12,R13),IF(AND(F3>=T9,F3<=T10),T12,T13)

    That is the formula that I am using to try and take a total from a cell, then see if it falls within ranges, and if it doesnt go onto the next until it finds the range which it falls in, then if it does show the result.


    Condition 1 0 Condition 1 51 Condition 1 151 Condition 1 1001
    Condition 2 50 Condition 2 150 Condition 2 1000 Condition 2 2000

    Result If True 10 Result If True 20 Result If True 40 Result If True 70
    Result If False 0 Result If False 0 Result If False 0 Result If False 0
    Attached Files Attached Files
    Last edited by DcoyElement; 02-23-2022 at 09:29 AM.

  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,196

    Re: IF and Formula Help

    See yellow banner on how to attach a sample workbook.
    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

  3. #3
    Registered User
    Join Date
    02-23-2022
    Location
    England
    MS-Off Ver
    Excel 365
    Posts
    4

    Re: IF and Formula Help

    Thank you, done that!

  4. #4
    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,196

    Re: IF and Formula Help

    Table in N:P (although Column O not actual required)

    in G3

    =VLOOKUP($F2,$N$1:$P$4,3,1)
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    02-23-2022
    Location
    England
    MS-Off Ver
    Excel 365
    Posts
    4

    Re: IF and Formula Help

    Was my method going to work? Or was it all wrong? Secondly, how would one expand the look up table?

  6. #6
    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,196

    Re: IF and Formula Help

    Was my method going to work?
    Corrected ....so try and understand why yours would not work .. logic of IF statement

    =IF(AND(F4>=$N$9,F4<=$N$10),$N$12,IF(AND(F4>=$P$9,F4<=$P$10),$P$12,IF(AND(F4>=$R$9,F4<=$R$10),$R$12,IF(AND(F4>=$T$9,F4<=$T$10),$T$12,0))))

    how would one expand the look up table?
    Just add new values and change the range in VLOOKUP

    =VLOOKUP($F2,$N$1:$P$4,3,1)

+ 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: 3
    Last Post: 03-24-2020, 07:27 AM
  2. Replies: 3
    Last Post: 01-10-2019, 09:34 AM
  3. Replies: 5
    Last Post: 02-16-2018, 06:50 AM
  4. Replies: 8
    Last Post: 09-22-2017, 05:41 AM
  5. Excel formula bar to display the result of the formula , not the formula?
    By max_max in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-18-2016, 07:15 PM
  6. Replies: 11
    Last Post: 06-06-2014, 03:34 PM
  7. how to hide formula in formula box, view lookup result in formula box?
    By vengatvj in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-14-2013, 04:06 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